Error Codes

Error Codes

All errors follow a consistent shape with a machine-readable code field. Parse code to handle errors programmatically.

HTTP code Meaning & Resolution
401 API_KEY_MISSING No API key was provided in the Request Header or Body.
401 INVALID_API_KEY The provided key doesn't exist, is inactive, expired, or revoked.
401 UNAUTHORIZED General authorization failure. Missing valid API context.
402 INSUFFICIENT_CREDITS Your account does not have enough credits to perform this request. Upgrade or recharge.
403 USER_INACTIVE Your account has been suspended or marked inactive. Contact support.
404 ENDPOINT_NOT_FOUND The requested API endpoint does not exist. Check the URL.
405 METHOD_NOT_ALLOWED The HTTP method used (e.g., GET) is not supported for this endpoint.
415 UNSUPPORTED_MEDIA_TYPE Unsupported media type. Please send application/json.
422 VALIDATION_ERROR Request payload failed validation. Check error.details for field-specific errors.
429 RATE_LIMIT_EXCEEDED Too many requests within a 1-minute window for your API key.
500 INTERNAL_SERVER_ERROR Unexpected server error. Safe to retry with exponential backoff.
503 PROVIDER_UNAVAILABLE The upstream AI provider is temporarily unavailable. Retry after a short delay.

Error Response Shape

JSON
{
  "success": false,
  "request_id": "req_w8x2b1l9zp",
  "error": {
    "code":    "RATE_LIMIT_EXCEEDED",
    "message": "Too many requests",
    "details": {
      "retry_after_seconds": 38
    }
  },
  "meta": {
    "version": "v1",
    "timestamp": "2026-04-12T18:00:00.000000Z"
  }
}

Ready to build?

Create your free account and make your first API call in minutes.