Queue statistics
The most relevant endpoints are located at https://api-nguc.weblink.se/swagger/#/Queue statistics.
Date and Time format specifiers:
- Datetime: (YYYY-MM-dd HH:mm:ss) eg. 2024-12-30 13:00:01
- Time: (HH:mm) eg. 13:00
weekdays: array of weekday indexes: 0-6
users: array of userId's
queues: array of queueId's
includeInternal = true/false (true also if userId == 0) == this indicates that the call was abandoned without being assigned to any agent.
includeExternal = true/false (true also if userId == -1) == external phone numbers
When downloading statistics the document can be requested in one of the following file formats.
- csv
- html
- xlsx
- excel
- xls
| Name | Type | Required | Description |
|---|---|---|---|
| reldays | integer | false |
Relative positive number of days before `to` query param that will be used to compute the `from` parameter.
|
| from | string | false |
Datetime from which calls will be included in the result, see the description for formats.
|
| to | string | false |
Datetime to which calls will be included in the result, see the description for formats. `NOW` will use the date and time of the API call.
Default value: NOW |
| from_time | string | false |
Time of day in format: `HH:mm:ss` (08:00:00). For each day calls after this time will be included.
Default value: 00:00:00 |
| to_time | string | false |
Time of day in format: `HH:mm:ss` (16:59:00). For each day calls before this time will be included.
Default value: 23:59:59 |
| weekdays | integer[] | false |
Zero based weekday index starting with monday to include calls for.
Default value: 0,1,2,3,4,5,6 |
| users | integer[] | false |
An array of user id's to get calls for.
|
| queues | integer[] | false |
an array of queue id's to get calls for.
|
| includeNone | bool-enum | false |
True indicates that we should limit calls that was not handled by any agent.
Allowed values: [true,false] Default value: false |
| includeExternal | bool-enum | false |
True indicates that we should limit calls that was handled by external phone numbers.
Allowed values: [true,false] Default value: false |
| limit | integer | false |
Limit the number of records returned (used for paginating result). The limit will be applied after sorting.
Default value: 20 |
| limit_from | integer | false |
Record offset to return data from (used for paginating result).
|
| order_by | string-enum | false |
The data type to sort by.
Allowed values: [datetime,id] Default value: datetime |
| order_dir | string-enum | false |
The order in which to sort the data.
Allowed values: [ASC,DESC] Default value: ASC |
| Title | Access |
|---|---|
| Queue Statistics | Read |
curl -G -H 'Authorization: Bearer <>' \ -d 'from=2024-01-01%2008%3A00%3A00' \ -d 'to=2024-06-13%2016%3A59%3A00' \ -d 'from_time=08%3A00' \ -d 'to_time=16%3A59' \ -d 'weekdays[]=0' \ -d 'weekdays[]=1' \ -d 'weekdays[]=2' \ -d 'weekdays[]=3' \ -d 'weekdays[]=4' \ -d 'weekdays[]=5' \ -d 'weekdays[]=6' \ -d 'graphDataTypes[]=answered' \ -d 'graphDataTypes[]=abandoned' \ -d 'graphDataTypes[]=unanswered' \ -d 'graphDataTypes[]=average_wait_time' \ -d 'graphDataTypes[]=average_talk_time' \ -d 'queues[]=26355' \ https://api-nguc.weblink.se/company/4/queuestat/calls"
{
"count": "3",
"limit": 20,
"limit_from": 0,
"calls": [
{
"id": "343601609",
"datetime": "2024-04-09 16:32:03",
"datetimeconnect": "2024-04-09 16:32:03",
"datetimeend": "2024-04-09 16:32:15",
"event": "ABANDON",
"agent": "NONE",
"clid": "9863",
"pbx_name": "Molle test",
"uniqueid": "s1-1712673123.342",
"wait_time": "12",
"talk_time": "0",
"ast_queue_id": "27028",
"queue_extension": "1338",
"call_guid": null,
"callerid": null,
"did": null
},
{
"id": "359787086",
"datetime": "2024-05-28 09:22:34",
"datetimeconnect": "2024-05-28 09:22:34",
"datetimeend": "2024-05-28 09:22:37",
"event": "ABANDON",
"agent": "NONE",
"clid": "9861",
"pbx_name": "Molle test",
"uniqueid": "s1-1716880954.44",
"wait_time": "3",
"talk_time": "0",
"ast_queue_id": "27028",
"queue_extension": "1338",
"call_guid": null,
"callerid": null,
"did": null
},
{
"id": "359787050",
"datetime": "2024-05-28 09:22:35",
"datetimeconnect": "2024-05-28 09:22:35",
"datetimeend": "2024-05-28 09:22:38",
"event": "ABANDON",
"agent": "NONE",
"clid": "9861",
"pbx_name": "Molle test",
"uniqueid": "s1-1716880955.53",
"wait_time": "3",
"talk_time": "0",
"ast_queue_id": "27028",
"queue_extension": "1338",
"call_guid": null,
"callerid": null,
"did": null
}
],
}
| Name | Type | Required | Description |
|---|---|---|---|
| downloadtype | string-enum | false |
fileformat used to generate report in.
Allowed values: [html,csv,excel,xlsx,xls,pdf] |
| from | string | false |
datetime in format: 'YYYY-mm-dd HH:mm:ss' (2024-12-01 08:00:00)
|
| to | string | false |
datetime in format: 'YYYY-mm-dd HH:mm:ss' (2024-12-24 16:59:00)
|
| weekdays | integer[] | false |
an array of weekday index's starting with monday as zero.
|
| users | integer[] | false |
an array of userid's to get calls for. Specify -1 to include calls that was answered by external phone numbers. Specify 0 to include calls that was abandoned hungup without being assigned to any agent.
|
| queues | integer[] | false |
an array of queueid's to get calls for.
|
| includeNone | bool | false | |
| includeExternal | bool | false |
true indicates that we should include calls that was handled by external phone numbers.
|
| limit | integer | false |
limit the number of records returned, used for pagination.
Default value: 20 |
| limit_from | integer | false |
used for pagination.
|
| order_by | string-enum | false |
the sort order in which to return the results.
Allowed values: [datetime,id] |
| order_dir | string-enum | false | Allowed values: [ASC,DESC] |
| Title | Access |
|---|---|
| Queue Statistics | Read |
| Name | Type | Required | Description |
|---|---|---|---|
| qsCallUniqueId | string | true |
unique call id
|
| Title | Access |
|---|---|
| Queue Statistics | Read |
| Name | Type | Required | Description |
|---|---|---|---|
| qsCallUniqueId | string | true |
unique call id
|
| Name | Type | Required | Description |
|---|---|---|---|
| downloadtype | string-enum | false |
fileformat used to generate report in.
Allowed values: [html,csv,excel,xlsx,xls,pdf] |
| Title | Access |
|---|---|
| Queue Statistics | Read |
| Name | Type | Required | Description |
|---|---|---|---|
| from | string | false |
datetime in format: 'yyyy-MM-dd HH:mm:ss' (2024-12-27 08:00:00)
|
| to | string | false |
datetime in format: 'yyyy-MM-dd HH:mm:ss' (2024-12-27 16:59:00)
|
| from_time | string | false |
time in format: 'HH:mm:ss' (08:00:00)
|
| to_time | string | false |
time in format : 'HH:mm:ss' (16:59:00)
|
| users | integer[] | false |
an array of userid's to get data for.
|
| queues | integer[] | false |
an array of queueid's to get data for.
|
| weekdays | integer[] | false |
an array of weekday indexes starting with monday as zero.
|
| includeNone | bool | false | |
| includeExternal | bool | false |
true indicates that we should include calls that was handled by external phone numbers.
|
| Title | Access |
|---|---|
| Queue Statistics | Read |