Cancel batch
Ask the provider to stop the batch. Requests that completed before it stops are charged.
ApiKeyAuthAuthorization<token>batch_id*stringThe id of a batch.
The batch
application/json- response
completed_at?integerUnix seconds.
completion_window*stringcreated_at*integerUnix seconds.
endpoint*stringerror_file_id?stringRead it with GET /v1/files/{file_id}/content.
errors?Present when the batch could not start. Nothing is charged for such a batch.
expires_at?integerUnix seconds. Set once the provider accepts the batch.
failed_at?integerUnix seconds.
id*stringinput_file_id*stringmetadata*object*"batch""batch"output_file_id?stringRead it with GET /v1/files/{file_id}/content.
request_counts*completed, failed, and cancelled stay 0 until the batch is settled.
status*stringfinalizing covers the provider's own finalizing step and the time OhMyGPT takes to settle the batch after the provider finishes. Results and final counts appear after it.
"validating""in_progress""finalizing""completed""failed""expired""cancelling""cancelled"curl -X POST 'https://api.ohmygpt.com/v1/batches/string/cancel'{ "completed_at": 0, "completion_window": "string", "created_at": 0, "endpoint": "string", "error_file_id": "string", "errors": { "data": [ { "code": "string", "message": "string" } ], "object": "list" }, "expires_at": 0, "failed_at": 0, "id": "string", "input_file_id": "string", "metadata": { "property1": "string", "property2": "string" }, "object": "batch", "output_file_id": "string", "request_counts": { "cancelled": 0, "completed": 0, "failed": 0, "total": 0 }, "status": "validating"}Still stuck? Live chat · [email protected] · Telegram group
Create transcription POST
Transcribe an audio file into text. Upload the audio as `multipart/form-data`; billing follows the usage the model reports, by audio duration or by tokens.
Create batch POST
Run the requests in an uploaded file asynchronously at the model's batch price, within 24 hours. Every line must use the same model. Creating the batch checks each line, then reserves the most the batch can cost from the balance. When the batch finishes it is charged once, for the requests that completed. Failed and cancelled requests are not charged. Without `Idempotency-Key`, each request creates a new batch, which is how the official OpenAI SDK calls it.