Qloud Docs

Errors

Error codes and which ones to retry.

Errors use the OpenAI error shape:

{
  "error": {
    "message": "Human-readable description",
    "type": "invalid_request",
    "code": "unsupported_service_tier",
    "param": "service_tier",
    "request_id": "qlo-..."
  }
}

Use code in your code. Do not use message.

StatusCodeCause
400invalid_requestThe request is not correct. For a batch file, the message gives the line number.
400context_length_exceededThe prompt and max_tokens are more than the context window.
400unsupported_service_tierservice_tier is not auto, default, realtime, async or flex.
400unsupported_completion_windowcompletion_window is not 24h or 4h.
400async_stream_unsupportedAn Async request has "stream": true.
401authentication_errorThe API key is missing, not valid or revoked.
402insufficient_creditsYour credit is too low. Add credit in the dashboard.
403permission_deniedThe key or organization does not have access, for example to Async and Batch.
404model_not_foundThe model ID is not known. IDs are case-sensitive.
404not_foundNo request, batch or file has this ID.
413payload_too_largeThe request is more than 20 MB, or the batch file is more than 200 MB.
429rate_limit_exceededToo many requests, tokens or running batches, or the daily spend limit.
502upstream_errorThe model could not be served.
503model_unavailableThe model or image and PDF processing is temporarily not available.
504timeoutThe request took too long.

Retries

Retry 429, 502, 503 and 504 with exponential backoff. If the response has retry-after, wait that number of seconds. Do not retry other 4xx errors without a change to the request.

Support

Email hello@qloud.sh. Include the x-qlo-request-id, the time, the model ID and the status code. Do not send your API key.

On this page