Errors
HTTP errors
Our API utilizes standard HTTP status codes to indicate errors:
400: The API key is invalid, or the requested model is not supported.
429: Your account or API key has run out of balance. Please add funds and try again.
Provider errors
In case of an error from the model provider, the error.metadata will contain relevant details. The format of this metadata is outlined below:
Error shapes
Errors are always returned as JSON, with the following structure:
The HTTP status code in the response will correspond to the error.code. Errors will occur under the following circumstances:
The request is invalid.
The API key/account has insufficient balance.
The API key is invalid.
If no issues are found, the response will return a 200 OK status. Any errors encountered during LLM processing will be included in the response body or sent as an SSE data event.
Last updated