NAME
Twilio::Rest::Taskrouter::V1::Workspace::Workflow::WorkflowRealTimeStatistics - The WorkflowRealTimeStatistics resource
SYNOPSIS
my $client = Twilio::Rest::Client->new($account_sid, $auth_token);
my $workflow_real_time_statistics = $client->taskrouter->v1->workspaces($workspace_sid)->workflows($workflow_sid)->real_time_statistics->fetch;
DESCRIPTION
This file holds WorkflowRealTimeStatisticsContext and WorkflowRealTimeStatisticsInstance. Methods that make a request throw Twilio::Exceptions::RestException on an error response.
WorkflowRealTimeStatisticsContext
Returned by $client->taskrouter->v1->workspaces($workspace_sid)->workflows($workflow_sid)->real_time_statistics. It makes no request until one of these methods is called.
fetch
my $workflow_real_time_statistics = $client->taskrouter->v1->workspaces($workspace_sid)->workflows($workflow_sid)->real_time_statistics->fetch(\%options);
Returns a WorkflowRealTimeStatisticsInstance.
The options are:
task_channel-
Only calculate real-time statistics on this TaskChannel. Can be the TaskChannel's SID or its
unique_name, such asvoice,sms, ordefault.
WorkflowRealTimeStatisticsInstance
See also Twilio::InstanceResource.
It has fetch, which work as they do on the context.
Its fields are:
- account_sid
-
The SID of the Account that created the Workflow resource.
- longest_task_waiting_age
-
The age of the longest waiting Task.
- longest_task_waiting_sid
-
The SID of the longest waiting Task.
- tasks_by_priority
-
The number of Tasks by priority. For example:
{"0": "10", "99": "5"}shows 10 Tasks at priority 0 and 5 at priority 99. - tasks_by_status
-
The number of Tasks by their current status. For example:
{"pending": "1", "reserved": "3", "assigned": "2", "completed": "5"}. - total_tasks
-
The total number of Tasks.
- url
-
The absolute URL of the Workflow statistics resource.
- workflow_sid
-
Returns the list of Tasks that are being controlled by the Workflow with the specified SID value.
- workspace_sid
-
The SID of the Workspace that contains the Workflow.
CONSTRUCTORS
new
Objects here come from the methods above, so there is no need to call new directly.
LICENSE
Copyright (c) 2026 Francisco Zarabozo. Released under the MIT License.