Errors — OneHub
All errors follow the OpenAI error format.
Docs
Docs Quick Start Authentication SDK Setup Available Models Rate Limits Chat Completions Streaming List Models Embeddings Image Generation Text to Speech Speech to Text Billing & Wallet Webhooks ErrorsErrors
Every error response uses the OpenAI error envelope:
{
"error": {
"message": "You exceeded your current quota",
"type": "insufficient_quota",
"code": "insufficient_quota"
}
}
Status codes
| Status | Description |
|---|---|
| 400 | Bad Request — malformed body or invalid parameter |
| 401 | Unauthorized — invalid or missing API key |
| 402 | Payment Required — insufficient wallet balance for a paid model |
| 403 | Forbidden — model not available on your plan |
| 404 | Not Found — unknown endpoint or model |
| 429 | Too Many Requests — rate limit exceeded |
| 500 | Internal Server Error — unexpected failure |
| 502 | Bad Gateway — upstream provider error |
| 503 | Service Unavailable — provider not configured |
Error types
| Type | Meaning |
|---|---|
invalid_request_error | The request was malformed or a parameter was invalid |
authentication_error | Bad or missing API key |
insufficient_quota | Wallet balance too low for a paid model |
permission_error | Model not unlocked on your plan |
rate_limit_exceeded | Too many requests |
api_error | Something went wrong upstream |