Skip to content

Errors

The error handling in 1.1 is admittedly very shallow.

All /v1 routes

Status Meaning What to do
401 The API key is invalid or not provided. Check the key with your operator

RAG completions and augmentation

POST /v1/rag/completions and POST /v1/rag/augmentation classify errors by who can fix them. The body is {"error": "…"}.

Status Cause What to do
400, other 4xx Your request was rejected, by RAG System or by the inference provider, for example an unknown model (404) or a conversation too long for the model Fix the request. error contains the original detail
503 RAG System or the provider is temporarily unavailable Retry later
500 Failure or misconfiguration inside RAG Web Retrying may help. Report it if it persists. The operator's logs have the details
502 RAG System or the inference provider failed Retrying may help. Report it if it persists

Only errors you can fix carry their detail. For 500 and 502 the message is generic, and the details are in the operator's logs.

For streamed completions, errors after the stream has started arrive as a final data: {"detail": "…"} chunk. See Streaming and citations.

Files: upload, status, delete

Status Cause
400 with validation details The upload isn't multipart/form-data, the file type isn't permitted, the file's content doesn't match its extension, or a .txt file isn't UTF-8
400 or 413 The file is larger than 256 MB
400 with an empty body Any other failure, including an unknown file id or collection

Models

GET /v1/models passes the provider's 429, 500, 502, 503 and 504 through. Treat them as temporary. Other provider errors become 500.

Plain chat completions

POST /v1/chat/completions returns 500 with {"message": "An error occured."} for any failure.