curl https://api.zerodrift.ai/api/v3/batches/BATCH_ID \
-H "x-api-key: YOUR_API_KEY"
{
"api_version": "v3",
"batch_id": "batch_3f2b8c1e9d0a4b7f8e6d5c4b3a291807",
"status": "ended",
"request_counts": { "processing": 0, "succeeded": 998, "errored": 2, "canceled": 0, "expired": 0 },
"total_items": 1000,
"skipped_items": 0,
"verdict_counts": { "approved": 941, "needs_changes": 44, "do_not_send": 13, "flagged": 57 },
"cost": {
"currency": "USD",
"estimate": { "units": 1000, "amount": "10.00" },
"actual": { "units": 998, "amount": "9.98" }
},
"model_engine": "anchor_3_0",
"metadata": { "name": "Q4 outbound review" },
"validation_scope": { "rulepacks": ["finra-2210"], "rules": ["guarantee_of_returns", "mnpi_leak"] },
"created_at": "2026-10-05T12:01:00Z",
"expires_at": "2026-10-06T12:01:00Z",
"in_progress_at": "2026-10-05T12:01:40Z",
"finalizing_at": "2026-10-05T12:39:10Z",
"cancel_initiated_at": null,
"canceled_before_start": false,
"ended_at": "2026-10-05T12:40:00Z",
"files_deleted_at": "2026-10-19T12:40:00Z",
"failure": null,
"report_status": "ready",
"results_url": "https://example-bucket.s3.amazonaws.com/batch-results/batch_3f2b8c1e9d0a4b7f8e6d5c4b3a291807/results.jsonl?X-Amz-Algorithm=...",
"results_url_expires_at": "2026-10-05T13:45:00Z",
"files": {
"jsonl": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"xlsx": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"workbook": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"pdf": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" }
}
}
{
"api_version": "v3",
"batch_id": "batch_e511e74dd1ea49ba8c5f4293a68427be",
"status": "failed",
"request_counts": { "processing": 0, "succeeded": 0, "errored": 0, "canceled": 0, "expired": 0 },
"total_items": 0,
"skipped_items": 0,
"model_engine": "anchor_3_0",
"metadata": { "name": "Docs sample audit" },
"created_at": "2026-12-02T19:43:52Z",
"expires_at": "2026-12-03T19:43:52Z",
"in_progress_at": null,
"ended_at": "2026-12-02T19:43:55Z",
"files_deleted_at": "2026-12-16T19:43:55Z",
"failure": {
"reason": "pricing_unavailable",
"errors": [
{ "code": "pricing_unavailable", "line": 0, "message": "pricing_unavailable: the customer has no billing account" }
]
},
"verdict_counts": { "approved": 0, "needs_changes": 0, "do_not_send": 0, "flagged": 0 },
"cost": { "currency": "USD", "estimate": null, "actual": null },
"report_status": null,
"results_url": null,
"files": { "jsonl": null, "xlsx": null, "workbook": null, "pdf": null }
}
Batches
Get a Batch
Follow a batch: status, counts by outcome and verdict, cost, and links to the results.
GET
/
api
/
v3
/
batches
/
{batch_id}
curl https://api.zerodrift.ai/api/v3/batches/BATCH_ID \
-H "x-api-key: YOUR_API_KEY"
{
"api_version": "v3",
"batch_id": "batch_3f2b8c1e9d0a4b7f8e6d5c4b3a291807",
"status": "ended",
"request_counts": { "processing": 0, "succeeded": 998, "errored": 2, "canceled": 0, "expired": 0 },
"total_items": 1000,
"skipped_items": 0,
"verdict_counts": { "approved": 941, "needs_changes": 44, "do_not_send": 13, "flagged": 57 },
"cost": {
"currency": "USD",
"estimate": { "units": 1000, "amount": "10.00" },
"actual": { "units": 998, "amount": "9.98" }
},
"model_engine": "anchor_3_0",
"metadata": { "name": "Q4 outbound review" },
"validation_scope": { "rulepacks": ["finra-2210"], "rules": ["guarantee_of_returns", "mnpi_leak"] },
"created_at": "2026-10-05T12:01:00Z",
"expires_at": "2026-10-06T12:01:00Z",
"in_progress_at": "2026-10-05T12:01:40Z",
"finalizing_at": "2026-10-05T12:39:10Z",
"cancel_initiated_at": null,
"canceled_before_start": false,
"ended_at": "2026-10-05T12:40:00Z",
"files_deleted_at": "2026-10-19T12:40:00Z",
"failure": null,
"report_status": "ready",
"results_url": "https://example-bucket.s3.amazonaws.com/batch-results/batch_3f2b8c1e9d0a4b7f8e6d5c4b3a291807/results.jsonl?X-Amz-Algorithm=...",
"results_url_expires_at": "2026-10-05T13:45:00Z",
"files": {
"jsonl": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"xlsx": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"workbook": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"pdf": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" }
}
}
{
"api_version": "v3",
"batch_id": "batch_e511e74dd1ea49ba8c5f4293a68427be",
"status": "failed",
"request_counts": { "processing": 0, "succeeded": 0, "errored": 0, "canceled": 0, "expired": 0 },
"total_items": 0,
"skipped_items": 0,
"model_engine": "anchor_3_0",
"metadata": { "name": "Docs sample audit" },
"created_at": "2026-12-02T19:43:52Z",
"expires_at": "2026-12-03T19:43:52Z",
"in_progress_at": null,
"ended_at": "2026-12-02T19:43:55Z",
"files_deleted_at": "2026-12-16T19:43:55Z",
"failure": {
"reason": "pricing_unavailable",
"errors": [
{ "code": "pricing_unavailable", "line": 0, "message": "pricing_unavailable: the customer has no billing account" }
]
},
"verdict_counts": { "approved": 0, "needs_changes": 0, "do_not_send": 0, "flagged": 0 },
"cost": { "currency": "USD", "estimate": null, "actual": null },
"report_status": null,
"results_url": null,
"files": { "jsonl": null, "xlsx": null, "workbook": null, "pdf": null }
}
Returns a batch’s status, its counts and cost, and, once it has ended, links to its results. Poll this until
status is ended or failed. Read-only API keys are allowed.
Path Parameters
The
batch_id from Create a Batch.Response
validating, in_progress, canceling, finalizing, ended or failed. See Follow the batch.Checked messages by verdict:
approved, needs_changes, do_not_send, and flagged (needs_changes + do_not_send). other counts any other verdict, such as send with caution, and appears only when it isn’t zero. Updated as messages finish.estimate: units and amount, set when the file is read. actual: what was billed, set when the batch ends.Set when
status is failed: reason (for example invalid_input, pricing_unavailable, quota_exceeded) and line-numbered errors.A link to the results JSONL, one line per message. Valid until
results_url_expires_at, an hour at most; get the batch again for a fresh link.Links to
jsonl, xlsx, workbook (the audit workbook) and pdf (the audit report). Each is {url, expires_at} or null. workbook and pdf are set once report_status is ready.Progress of the audit workbook and PDF report built after the batch ends:
pending, building, ready or failed.When the input, results and reports are deleted: 14 days after the batch ends. After that,
results_url and files are null. The batch record stays.curl https://api.zerodrift.ai/api/v3/batches/BATCH_ID \
-H "x-api-key: YOUR_API_KEY"
{
"api_version": "v3",
"batch_id": "batch_3f2b8c1e9d0a4b7f8e6d5c4b3a291807",
"status": "ended",
"request_counts": { "processing": 0, "succeeded": 998, "errored": 2, "canceled": 0, "expired": 0 },
"total_items": 1000,
"skipped_items": 0,
"verdict_counts": { "approved": 941, "needs_changes": 44, "do_not_send": 13, "flagged": 57 },
"cost": {
"currency": "USD",
"estimate": { "units": 1000, "amount": "10.00" },
"actual": { "units": 998, "amount": "9.98" }
},
"model_engine": "anchor_3_0",
"metadata": { "name": "Q4 outbound review" },
"validation_scope": { "rulepacks": ["finra-2210"], "rules": ["guarantee_of_returns", "mnpi_leak"] },
"created_at": "2026-10-05T12:01:00Z",
"expires_at": "2026-10-06T12:01:00Z",
"in_progress_at": "2026-10-05T12:01:40Z",
"finalizing_at": "2026-10-05T12:39:10Z",
"cancel_initiated_at": null,
"canceled_before_start": false,
"ended_at": "2026-10-05T12:40:00Z",
"files_deleted_at": "2026-10-19T12:40:00Z",
"failure": null,
"report_status": "ready",
"results_url": "https://example-bucket.s3.amazonaws.com/batch-results/batch_3f2b8c1e9d0a4b7f8e6d5c4b3a291807/results.jsonl?X-Amz-Algorithm=...",
"results_url_expires_at": "2026-10-05T13:45:00Z",
"files": {
"jsonl": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"xlsx": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"workbook": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" },
"pdf": { "url": "https://example-bucket.s3.amazonaws.com/...", "expires_at": "2026-10-05T13:45:00Z" }
}
}
{
"api_version": "v3",
"batch_id": "batch_e511e74dd1ea49ba8c5f4293a68427be",
"status": "failed",
"request_counts": { "processing": 0, "succeeded": 0, "errored": 0, "canceled": 0, "expired": 0 },
"total_items": 0,
"skipped_items": 0,
"model_engine": "anchor_3_0",
"metadata": { "name": "Docs sample audit" },
"created_at": "2026-12-02T19:43:52Z",
"expires_at": "2026-12-03T19:43:52Z",
"in_progress_at": null,
"ended_at": "2026-12-02T19:43:55Z",
"files_deleted_at": "2026-12-16T19:43:55Z",
"failure": {
"reason": "pricing_unavailable",
"errors": [
{ "code": "pricing_unavailable", "line": 0, "message": "pricing_unavailable: the customer has no billing account" }
]
},
"verdict_counts": { "approved": 0, "needs_changes": 0, "do_not_send": 0, "flagged": 0 },
"cost": { "currency": "USD", "estimate": null, "actual": null },
"report_status": null,
"results_url": null,
"files": { "jsonl": null, "xlsx": null, "workbook": null, "pdf": null }
}
Errors
| Status | Code | Meaning |
|---|---|---|
400 | batch_id is malformed. | |
404 | batch_not_found | No batch with this ID is yours. |

