GET
/v1/batchesList batches
Your batches, newest first.
Authentication: Bearer API key in the Authorization header
Query parameters
limitintegerPage size from 1 to 100.
afterstringReturn batches after this batch id.
Responses
200A page of batches.
Response
objectstringdataarray<object>data
idstringobjectstringendpointstringerrorsobject | nullRejected input lines:
{object: list, data: [{code, message, line, custom_id}]}.input_file_idstringcompletion_windowstringstatusenumoutput_file_idstring | nullerror_file_idstring | nullcreated_atintegerexpires_atinteger | nullcompleted_atinteger | nullfailed_atinteger | nullexpired_atinteger | nullcancelled_atinteger | nullrequest_countsobjectAccepted lines only; rejected lines are in
errors.request_counts
totalintegercompletedintegerfailedinteger
metadataobject | null
first_idstring | nulllast_idstring | nullhas_moreboolean
401The key is missing, malformed, expired or revoked.
Response
errorobjecterror
messagestringWhat went wrong and how to fix it.
typestringFor example
invalid_request_error,authentication_error,permission_error,rate_limit_error,insufficient_quota,api_error.codestringThe stable error code.
paramstring | nullThe request field at fault, when there is one.
refusal_reasonenumPresent only on
code: refusal.
Request
curl https://api.experientiallabs.ai/v1/batches \
-H "Authorization: Bearer YOUR_API_KEY"Response
{
"object": "list",
"data": [
{
"id": "batch_9c2e4b7a1f0d3e6c5b8a2d4f",
"object": "batch",
"endpoint": "/v1/chat/completions",
"errors": null,
"input_file_id": "file_3f9a1c0e7b2d4a6f8e1c2b3d",
"completion_window": "24h",
"status": "completed",
"output_file_id": "file_7b1d9e3a5c2f4086b4a1e9c7",
"error_file_id": null,
"created_at": 1795132800,
"expires_at": 1795219200,
"completed_at": 1795136400,
"failed_at": null,
"expired_at": null,
"cancelled_at": null,
"request_counts": {
"total": 2,
"completed": 2,
"failed": 0
},
"metadata": {
"job": "nightly"
}
}
],
"first_id": "batch_9c2e4b7a1f0d3e6c5b8a2d4f",
"last_id": "batch_9c2e4b7a1f0d3e6c5b8a2d4f",
"has_more": false
}https://api.experientiallabs.ai/v1/batches