Errors
When a request fails, the API returns a non-2xx status code and a JSON body describing the error.
Error Response Format
Every error response has the same shape:
{
"error": {
"code": "error_code",
"message": "Human-readable message"
}
}
code- a machine-readable string. Stable across versions. Use this in your integration logic.message- a human-readable message. Translated to the panel's configured language. Do not parse it. It can change between releases.
Error Codes
| Code | HTTP Status | Meaning |
|---|---|---|
invalid_request |
400 | Malformed body, missing fields, or invalid values |
unauthorized |
401 | Missing, invalid, revoked, or expired token |
forbidden |
403 | Token is valid but not allowed to access this resource |
insufficient_scope |
403 | Token does not have the scope required by this endpoint |
not_found |
404 | The requested resource does not exist |
rate_limited |
429 | Rate limit exceeded for this token |
internal_error |
500 | Server-side failure |
api_disabled |
503 | API is disabled by the administrator |
Handling Errors
Match on code, not on message or HTTP status alone.
invalid_request- fix the request body. The message will often tell you which field is wrong.unauthorized- check the token. See Authentication for the debugging checklist.forbidden- the token is valid but the caller cannot access this resource. On admin-only endpoints, this means the token belongs to a non-admin user. On resource endpoints, this means the resource belongs to another user.insufficient_scope- the token is valid but missing a scope. Create a new token with the required scope.not_found- the resource does not exist or was deleted.rate_limited- respect theRetry-Afterheader and slow down.internal_error- retry once after a short delay. If it persists, check the panel logs.api_disabled- the API is turned off by an admin. Nothing the client can do except wait.
Rate Limiting
When a token exceeds its rate limit, the API returns 429 Too Many Requests with code rate_limited and a Retry-After header:
HTTP/1.1 429 Too Many Requests
Retry-After: 42
Content-Type: application/json
{
"error": {
"code": "rate_limited",
"message": "Rate limit exceeded. Try again in 42 seconds."
}
}
Retry-After is in seconds. Wait at least that long before the next request. Retries that ignore the header can extend the cooldown.
Rate limits are per token and configured by the admin. See API Settings for the admin-side controls.
For behavior of pagination parameters and out-of-range pages, see Pagination.
Related
- Authentication - token format and auth failure reference
- Endpoints - endpoint list
- API Settings - admin controls for rate limit and API state