Fetch workers cumulative statistics

GET /v1/Workspaces/{WorkspaceSid}/Workers/CumulativeStatistics

TODO: Resource-level docs

Path parameters

  • WorkspaceSid string Required

    The SID of the Workspace with the resource to fetch.

Query parameters

  • EndDate string(date-time)

    Only calculate statistics from this date and time and earlier, specified in ISO 8601 format.

  • Minutes integer

    Only calculate statistics since this many minutes in the past. The default 15 minutes. This is helpful for displaying statistics for the last 15 minutes, 240 minutes (4 hours), and 480 minutes (8 hours) to see trends.

  • StartDate string(date-time)

    Only calculate statistics from this date and time and later, specified in ISO 8601 format.

  • Only calculate cumulative statistics on this TaskChannel. Can be the TaskChannel's SID or its unique_name, such as voice, sms, or default.

Responses

  • OK

    Hide response attributes Show response attributes object
    • account_sid string | null

      The SID of the Account that created the resource

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^AC[0-9a-fA-F]{32}$.

    • The minimum, average, maximum, and total time that Workers spent in each Activity

    • end_time string(date-time) | null

      The end of the interval during which these statistics were calculated

    • The total number of Reservations that were accepted

    • The total number of Reservations that were canceled

    • reservations_created integer | null

      The total number of Reservations that were created

    • The total number of Reservations that were rejected

    • The total number of Reservations that were rescinded

    • The total number of Reservations that were timed out

    • start_time string(date-time) | null

      The beginning of the interval during which these statistics were calculated

    • url string(uri) | null

      The absolute URL of the Workers statistics resource

    • workspace_sid string | null

      The SID of the Workspace that contains the Workers

      Minimum length is 34, maximum length is 34. Format should match the following pattern: ^WS[0-9a-fA-F]{32}$.

GET /v1/Workspaces/{WorkspaceSid}/Workers/CumulativeStatistics
curl \
 -X GET https://taskrouter.twilio.com/v1/Workspaces/{WorkspaceSid}/Workers/CumulativeStatistics \
 --user "username:password"
Response examples (200)
{
  "account_sid": "string",
  "activity_durations": [],
  "end_time": "2023-05-04T09:42:00+00:00",
  "reservations_accepted": 42,
  "reservations_canceled": 42,
  "reservations_created": 42,
  "reservations_rejected": 42,
  "reservations_rescinded": 42,
  "reservations_timed_out": 42,
  "start_time": "2023-05-04T09:42:00+00:00",
  "url": "https://example.com",
  "workspace_sid": "string"
}
Response examples (200)
{
  "account_sid": "string",
  "activity_durations": [],
  "end_time": "2024-05-04T09:42:00+00:00",
  "reservations_accepted": 42,
  "reservations_canceled": 42,
  "reservations_created": 42,
  "reservations_rejected": 42,
  "reservations_rescinded": 42,
  "reservations_timed_out": 42,
  "start_time": "2024-05-04T09:42:00+00:00",
  "url": "https://example.com",
  "workspace_sid": "string"
}