Endpoint
GET https://api.graine.ai/api/v1/batches/{batch_id}
Returns a batch with live counters computed in real-time from the contacts collection — stored counters are always overridden so the response never shows stale data.
Path Parameters
| Parameter | Type | Required | Description |
|---|
batch_id | string | Yes | Batch identifier |
| Header | Required | Description |
|---|
Authorization | Yes | Bearer gat_<token> |
Example Request
curl "https://api.graine.ai/api/v1/batches/btc_xyz001" \
-H "Authorization: Bearer gat_your_token"
Response
200 OK
{
"batch_id": "btc_xyz001",
"campaign_id": "cmp_abc123",
"organization_id": "org_xyz",
"status": "in_progress",
"total_contacts": 100,
"concurrency_limit": 10,
"max_retries_override": null,
"scheduled_start": null,
"call_context": {},
"metadata": {},
"counters": {
"pending": 22,
"dispatched": 3,
"in_flight": 5,
"retrying": 4,
"completed": 58,
"failed": 3,
"busy": 5,
"no_answer": 0
},
"created_at": "2026-05-08T09:00:00Z",
"updated_at": "2026-05-10T08:30:00Z"
}
counters are computed live from the contacts collection on every request. They are never the stale stored counters — the frontend always sees accurate data.
404 Not Found
{ "detail": "Batch not found" }