[DOCS]
Errors
Every error uses the OpenAI envelope, so SDK error handling works unchanged. The code field is stable and machine-readable. This page lists every code the platform can emit.
ERROR ENVELOPE
{
"error": {
"message": "This API key is disabled. Re-enable it from your dashboard.",
"type": "authentication_error",
"code": "api_key_disabled"
}
}All error codes
| HTTP | CODE | TYPE | MESSAGE |
|---|---|---|---|
| 401 | missing_api_key | authentication_error | Missing API key. Pass it as: Authorization: Bearer sk-blaze-... |
| 401 | invalid_api_key | authentication_error | Invalid API key. |
| 403 | api_key_disabled | authentication_error | This API key is disabled. Re-enable it from your dashboard. |
| 400 | invalid_request | invalid_request_error | The request body is invalid. |
| 404 | model_not_found | invalid_request_error | Unknown model. See GET /v1/models for available models. |
| 404 | model_not_available | invalid_request_error | This model is not available yet. See blazeinference.com/models. |
| 413 | payload_too_large | invalid_request_error | Request body exceeds the 5 MB limit. |
| 400 | context_length_exceeded | invalid_request_error | The request exceeds the model's context window. |
| 429 | quota_exceeded | rate_limit_error | Daily free quota reached (100 successful requests/day). Resets at midnight UTC. |
| 429 | rate_limited | rate_limit_error | Too many requests. Slow down and retry shortly. |
| 502 | inference_error | api_error | Inference failed. This request did not count against your quota. Please retry. |
| 504 | inference_timeout | api_error | Inference timed out. Please retry. |
| 500 | internal_error | api_error | Internal error. Please retry. |
| 400 | invalid_otp | invalid_request_error | Invalid code. |
| 400 | otp_expired | invalid_request_error | This code has expired or was already used. Request a new one. |
Errors during streaming
If a stream fails after it has started, the final SSE event carries the same envelope (typically inference_error or inference_timeout) followed by data: [DONE]. Failed streams never count against your quota.