Batches
List batches for a provider.
Non-master keys only see batches they own in their own workspace (plus legacy batches without an ownership marker, or without a recorded workspace); the page is filtered after the provider call, so a page may contain fewer than limit items.
Enter your API key here (sent as Otari-Key header).
Successful Response
Validation Error
GET /api/v1/batches?provider=text HTTP/1.1
Otari-Key: YOUR_API_KEY
Accept: */*
No content
Create a batch of LLM requests for asynchronous processing.
Authentication modes:
Master key + user field: Use specified user (must exist)
API key + user field: Use specified user (must exist)
API key without user field: Use the shared "default" user
Enter your API key here (sent as Otari-Key header).
24hSuccessful Response
Validation Error
POST /api/v1/batches HTTP/1.1
Otari-Key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 182
{
"completion_window": "24h",
"metadata": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"model": "text",
"requests": [
{
"body": {
"ANY_ADDITIONAL_PROPERTY": "anything"
},
"custom_id": "text"
}
],
"user": "text"
}No content
Retrieve the status of a batch.
Enter your API key here (sent as Otari-Key header).
Successful Response
Validation Error
GET /api/v1/batches/{batch_id}?provider=text HTTP/1.1
Otari-Key: YOUR_API_KEY
Accept: */*
No content
Cancel a batch.
Enter your API key here (sent as Otari-Key header).
Successful Response
Validation Error
POST /api/v1/batches/{batch_id}/cancel?provider=text HTTP/1.1
Otari-Key: YOUR_API_KEY
Accept: */*
No content
Retrieve the results of a completed batch.
Enter your API key here (sent as Otari-Key header).
Successful Response
Batch is not yet complete
Validation Error
LLM provider error
GET /api/v1/batches/{batch_id}/results?provider=text HTTP/1.1
Otari-Key: YOUR_API_KEY
Accept: */*
No content
Last updated
Was this helpful?
