Common Error Codes & Troubleshooting Guide
When using the API, if you receive an HTTP response other than 200 OK, please refer to the table below to troubleshoot the cause:
| HTTP Status Code | Error Type | Cause Analysis | Solution |
|---|---|---|---|
401 Unauthorized | Authentication Failure | 1. API Key is incorrect or has been disabled 2. Header format does not include Bearer | Check if the Key is copied completely; confirm the Header is Authorization: Bearer sk-xxx |
402 Payment Required | Insufficient Quota | 1. Account global balance is exhausted 2. The quota set for a single API Key has been used up | Go to the console to recharge with a redemption code, or edit the token to increase the quota limit |
429 Too Many Requests | Rate Limit / Upstream Rate Limiting | 1. Request frequency exceeds the group RPM limit 2. Upstream provider triggered Rate Limit | Reduce concurrent frequency, or contact the administrator to switch to a high-concurrency VIP group / add upstream channels |
404 Not Found | Model Does Not Exist | The requested model name is not enabled in the gateway or is misspelled | Confirm the exact supported model name in the console “Model Square” or by calling the /v1/models interface |
502 Bad Gateway | Upstream Channel Exception | Upstream provider (OpenAI/Anthropic, etc.) server failure or network interruption | The gateway will automatically try to retry other nodes; if the error persists, please submit a ticket to contact operations |
504 Gateway Timeout | Request Timeout | Long-text reasoning response time is too long, exceeding the gateway timeout limit (e.g. 120s) | It is recommended to enable stream: true streaming transmission, or use context compression to shorten the Prompt |