Get Batch Progress
Get detailed progress information for a batch call operation
Headers
x-api-keystringrequiredAPI key used for authenticating requests to the API.
x-workspace-idstringrequiredWorkspace identifier for the API.
Path Parameters
batchIdstringrequiredThe unique identifier of the batch call operation
Response
statusstringCurrent status of the batch operation
isCompletebooleanWhether the batch operation has finished
waitingnumberNumber of calls waiting in queue
activenumberNumber of calls currently being processed
completednumberNumber of successfully completed calls
failednumberNumber of failed calls
totalnumberTotal number of calls in the batch
startTimenumberTimestamp when the batch started processing
lastCompletedTimenumberTimestamp of the last completed call
completedTimenumberTimestamp when the batch was completed (if finished)
averageCallDurationnumberAverage duration of completed calls in seconds
recent_callsarrayArray of recent call results for monitoring
Example Usage
curl -X GET "https://api.trillet.ai/v1/api/batch-calls/batch_7891011121314/status" \
-H "x-api-key: YOUR_API_KEY" \
-H "x-workspace-id: YOUR_WORKSPACE_ID"
Example Response
{
"status": "processing",
"isComplete": false,
"waiting": 45,
"active": 5,
"completed": 95,
"failed": 5,
"total": 150,
"startTime": 1703097600000,
"lastCompletedTime": 1703101200000,
"completedTime": null,
"averageCallDuration": 45.2,
"recent_calls": [
{
"jobId": "call_123",
"status": "completed",
"phone_number": "+1234567890",
"completedAt": 1703101200000,
"duration": 42
},
{
"jobId": "call_124",
"status": "failed",
"phone_number": "+1987654321",
"failedAt": 1703101150000,
"error": "Number busy"
}
]
}
Error Responses
errorstringError message describing what went wrong
Common Error Codes:
500- Server error retrieving batch progress information
Progress Tracking
This endpoint provides real-time progress updates for your batch call operations. Use it to build dashboards or monitor batch completion in your applications.
