> For a complete documentation index, fetch https://docs.voximplant.ai/llms.txt # GetACDOperatorStatistics POST https://api.voximplant.com/platform_api/GetACDOperatorStatistics Get statistics for calls distributed to users (referred as 'operators') via the 'ACD' module. This method can filter statistic based on operator ids, queue ids and date-time interval. It can also group results by day or hour. Allowed roles: `Owner`, `Admin`, `Developer`, `Supervisor`, `User manager`. **Example request:** Get AC and TT statistics for two operators and the queue from the specified date. Reference: https://docs.voximplant.ai/api-reference/management-api/reference/queues/get-acd-operator-statistics ## Authentication - `Authorization` header (bearer token, required) — Voximplant Management API uses signed JWT tokens generated from your service-account private key. Pass the token in the `Authorization` header as a Bearer value: ``` Authorization: Bearer $VOXIMPLANT_TOKEN ``` See [Authorization](/api-reference/management-api/authorization) for ready-to-copy snippets in bash, Python, Node.js and Go that turn your `credentials.json` into a token. ## Request ### Query parameters - `from_date` (string, required) — Date and time of statistics interval begin. Time zone is UTC, format is 24-h 'YYYY-MM-DD HH:mm:ss' - `to_date` (string, optional, default: current date and time) — Date and time of statistics interval begin. Time zone is UTC, format is 24-h 'YYYY-MM-DD HH:mm:ss' - `acd_queue_id` (list of integer, optional) — The ACD queue ID list separated by semicolons (;). Use the 'all' value to select all ACD queues - `user_id` (list of integer, required) — The user ID list separated by semicolons (;). Use the 'all' value to select all users - `abbreviation` (boolean, optional, default: true) — Whether key names in returned JSON are abbreviated to reduce response byte size. The abbreviations are: 'SA' for 'SpeedOfAnswer', 'HT' for 'HandlingTime', 'TT' for 'TalkTime', 'ACW' for 'AfterCallWork', 'TDT' for 'TotalDialingTime', 'THT' for 'TotalHandlingTime', 'TTT' for 'TotalTalkTime', 'TACW' for 'TotalAfterCallWork', 'AC' for 'AnsweredCalls', 'UAC' for 'UnansweredCalls' - `report` (list of string, optional) — List of item names abbreviations separated by semicolons (;). Returned JSON includes keys only for the selected items. Special 'all' value defines all possible items, see [ACDOperatorStatisticsType] for a complete list. See 'abbreviation' description for complete abbreviation list - `aggregation` (string, optional, default: none) — Specifies how records are grouped by date and time. If set to 'day', the criteria is a day number. If set to 'hour_of_day', the criteria is a 60-minute interval within a day. If set to 'hour', the criteria is both day number and 60-minute interval within that day. If set to 'none', records are not grouped by date and time - `group` (string, optional, default: user) — If set to 'user', first-level array in the resulting JSON groups records by the user ID, and second-level array groups them by date according to the 'aggregation' parameter. If set to 'aggregation', first-level array in the resulting JSON groups records according to the 'aggregation' parameter, and second-level array groups them by the user ID ## Response ### 200 Successful response - `result` (list of ACDOperatorAggregationGroupType, optional) — List of groups, grouped by user ID or date according to the 'group' method call argument ## Types ### ACDOperatorAggregationGroupType The [GetACDOperatorStatistics] function result item. - `user_id` (AcdOperatorAggregationGroupTypeUserId, optional) — If aggregation is enabled, contains user ID for the results - `date` (string, optional) — Date string as returned by the Management API. If aggregation is enabled, contains UTC date for the results in 24-h 'YYYY-MM-DD' format - `hour` (integer, optional) — If aggregation is enabled, contains the 60-minute interval number from 1 to 24 - `statistics` (list of ACDOperatorStatisticsType, optional) — List of records grouped by date or user ID according to the 'group' method call argument ### AcdOperatorAggregationGroupTypeUserId If aggregation is enabled, contains user ID for the results ### ACDOperatorStatisticsType Individual record in the [ACDOperatorAggregationGroupType] group. - `user_id` (string, optional) — If aggregation is enabled, contains user ID for the results - `date` (string, optional) — Date string as returned by the Management API. If aggregation is enabled, contains UTC date for the results in 24-h 'YYYY-MM-DD' format - `hour` (integer, optional) — If aggregation is enabled, contains the 60-minute interval number from 1 to 24 - `SA` (ACDStatisticsItemType, optional) — Delay between a call started to ring and operator answered it. Name is 'SpeedOfAnswer' if 'abbreviation' is set to 'false' - `TT` (ACDStatisticsItemType, optional) — Time between operator answering and ending a call. Name is 'TalkTime' if 'abbreviation' is set to 'false' - `ACW` (ACDStatisticsItemType, optional) — Time between operator ended a call and changed status to a one different from the 'AFTER_SERVICE'. This time is tracked only if operator changed status to 'AFTER_SERVICE' after the call. Name is 'AfterCallWork' if 'abbreviation' is set to 'false' - `HT` (ACDStatisticsItemType, optional) — Sum of 'TalkTime' and 'AfterCallWork'. Name is 'HandlingTime' if 'abbreviation' is set to 'false' - `AC` (integer, optional) — Number of answered calls. Name is 'AnsweredCalls' if 'abbreviation' is set to 'false' - `UAC` (integer, optional) — Number of unanswered calls. Name is 'UnansweredCalls' if 'abbreviation' is set to 'false' - `TDT` (integer, optional) — Sum of delays between calls started to ring and operator answered them, in seconds. Name is 'TotalDialingTime' if 'abbreviation' is set to 'false' - `THT` (integer, optional) — Sum of 'HandlingTime', in seconds. Name is 'TotalHandlingTime' if 'abbreviation' is set to 'false' - `TTT` (integer, optional) — Sum of 'TalkTime', in seconds. Name is 'TotalTalkTime' if 'abbreviation' is set to 'false' - `TACW` (integer, optional) — Sum of 'AfterCallWork', in seconds. Name is 'TotalAfterCallWork' if 'abbreviation' is set to 'false' ### ACDStatisticsItemType Individual statistics item in the [ACDOperatorStatisticsType], [ACDQueueStatisticsType], and [ACDOperatorStatusStatisticsDetail] records. - `min` (integer, optional) — Minimum value over the aggregated interval, in seconds - `avg` (integer, optional) — Average value over the aggregated interval, in seconds - `max` (integer, optional) — Maximum value over the aggregated interval, in seconds - `count` (integer, optional) — Samples count over the aggregated interval - `sum` (integer, optional) — Sum of all samples over the aggregated interval, in seconds ## Examples **Response** ```json { "result": [ { "user_id": 1768, "statistics": [ { "date": "2021-04-08", "TT": { "min": 31, "avg": 234, "max": 740, "count": 18, "sum": 4226 }, "AC": 18 }, { "date": "2021-04-09", "TT": { "min": 34, "avg": 178, "max": 1089, "count": 29, "sum": 5170 }, "AC": 29 } ] }, { "user_id": 1769, "statistics": [ { "date": "2021-04-08", "TT": { "min": 3, "avg": 115, "max": 591, "count": 112, "sum": 12948 }, "AC": 112 }, { "date": "2021-04-09", "TT": { "min": 3, "avg": 107, "max": 396, "count": 110, "sum": 11799 }, "AC": 110 } ] } ] } ``` **SDK Code** ```python Example 1 import requests url = "https://api.voximplant.com/platform_api/GetACDOperatorStatistics" querystring = {"from_date":"2026-04-28 17:30:00","user_id":"[1]"} headers = {"Authorization": "Bearer "} response = requests.post(url, headers=headers, params=querystring) print(response.json()) ``` ```javascript Example 1 const url = 'https://api.voximplant.com/platform_api/GetACDOperatorStatistics?from_date=2026-04-28+17%3A30%3A00&user_id=%5B1%5D'; const options = {method: 'POST', headers: {Authorization: 'Bearer '}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go Example 1 package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api.voximplant.com/platform_api/GetACDOperatorStatistics?from_date=2026-04-28+17%3A30%3A00&user_id=%5B1%5D" req, _ := http.NewRequest("POST", url, nil) req.Header.Add("Authorization", "Bearer ") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby Example 1 require 'uri' require 'net/http' url = URI("https://api.voximplant.com/platform_api/GetACDOperatorStatistics?from_date=2026-04-28+17%3A30%3A00&user_id=%5B1%5D") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["Authorization"] = 'Bearer ' response = http.request(request) puts response.read_body ``` ```java Example 1 import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api.voximplant.com/platform_api/GetACDOperatorStatistics?from_date=2026-04-28+17%3A30%3A00&user_id=%5B1%5D") .header("Authorization", "Bearer ") .asString(); ``` ```php Example 1 request('POST', 'https://api.voximplant.com/platform_api/GetACDOperatorStatistics?from_date=2026-04-28+17%3A30%3A00&user_id=%5B1%5D', [ 'headers' => [ 'Authorization' => 'Bearer ', ], ]); echo $response->getBody(); ``` ```csharp Example 1 using RestSharp; var client = new RestClient("https://api.voximplant.com/platform_api/GetACDOperatorStatistics?from_date=2026-04-28+17%3A30%3A00&user_id=%5B1%5D"); var request = new RestRequest(Method.POST); request.AddHeader("Authorization", "Bearer "); IRestResponse response = client.Execute(request); ``` ```swift Example 1 import Foundation let headers = ["Authorization": "Bearer "] let request = NSMutableURLRequest(url: NSURL(string: "https://api.voximplant.com/platform_api/GetACDOperatorStatistics?from_date=2026-04-28+17%3A30%3A00&user_id=%5B1%5D")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```