Get Batch Progress
Get the job counters and percent complete for a batch call operation
Headers
x-workspace-idstringrequiredWorkspace identifier for the API.
Path Parameters
batchIdstringrequiredThe 10-character batch ID returned by Start Batch Calls.
Response
batchIdstringThe batch ID.
totalnumberTotal jobs in the batch
completednumberDial jobs that finished
failednumberDial jobs that failed. Cancelled calls are not counted here.
cancellednumberCalls cancelled before they were dialled, by Cancel Batch Operation, Cancel Batch Job or Cancel Batch Contact.
waitingnumberJobs waiting in the queue
activenumberJobs currently being placed
progressnumberPercent of jobs completed, rounded to a whole number (0-100). Failed jobs are not counted as completed.
lastUpdatednumberTime these counters were read, in Unix milliseconds.
Example Usage
curl -X GET "https://api.trillet.ai/v1/api/batch-calls/k3j9x0a1bq/status" \
-H "x-api-key: YOUR_API_KEY" \
-H "x-workspace-id: YOUR_WORKSPACE_ID"
Example Response
{
"batchId": "k3j9x0a1bq",
"total": 150,
"completed": 95,
"failed": 5,
"cancelled": 0,
"waiting": 45,
"active": 5,
"progress": 63,
"lastUpdated": 1793284800000
}
Error Responses
errorstringError message describing what went wrong
Common Error Codes:
404-Batch not found: the batch doesn't exist or belongs to another workspace500- Server error retrieving batch progress
Counters are kept for 7 days. After that, or before a scheduled batch starts, every counter reads 0. Use Get Batch Status for the batch's overall status.
Last updated on