Errors
LLMRPM uses structured JSON for gateway-generated failures, while model-originated errors are passed through with their original status and payload.
Error shape
Gateway errors generated by LLMRPM — authentication, subscription, quota, and gateway availability failures — use the OpenAI-style shape below, with matching message, type, and code fields:
{
"error": {
"message": "7-day request limit exceeded. Try again after 2026-09-02T09:14:03.000Z.",
"type": "quota_exhausted",
"code": "quota_exhausted"
}
}Errors returned by the target model itself are passed through unchanged. Use the HTTP status first, then inspect the provider-specific payload when the error did not originate from the LLMRPM gateway.
Status codes
| Status | Meaning | How to handle it |
|---|---|---|
| 400 | The target model rejected your request body — often a missing required field or an invalid parameter for that model. | Check the model-specific error message and fix the request; retrying without changes will fail again. |
| 401 | Missing, invalid, or revoked API key. | Check the Authorization header and confirm the key is still active in the dashboard. |
| 402 | Generation request made without an active subscription. | Subscribe on the pricing page; do not retry until a plan is active. |
| 403 | Email not verified, or the usage endpoint was called without an active subscription. | Verify the account email or activate a subscription, depending on the response message. |
| 429 | A 5-hour, 24-hour, or 7-day request window is exhausted. | Read the reset time in the message or check GET /api/v1/usage, then retry after that boundary. |
| 5xx | Gateway misconfiguration or an unreachable/failing upstream model. | Safe to retry with backoff. Persistent failures should be reported via contact. |
Retry guidance
Only 429 and 5xx responses are safe to retry automatically. A quota 429 includes the exact reset time; wait until that boundary rather than repeatedly retrying.
5xx failures, use exponential backoff and jitter: wait roughly 1s, then 2s, then 4s, capping around 30–60s between attempts. For a quota429, pause until the exhausted window resets.Do not retry 400, 401, 402, or 403 without changing something first — the request will fail identically every time until the underlying issue (a bad parameter, a bad key, a missing subscription, an unverified email) is fixed.