Guides
Errors
Error shapes, status codes and what to do about each one.
Every response is wrapped in an envelope carrying a request_id
(also echoed in the X-Request-Id header — include it when contacting support):
{ "data": { ... }, "request_id": "req_..." } // success
{ "error": { "code": "...", "message": "..." }, "request_id": "req_..." } // error
Authentication failures emitted before request-id middleware use a flat
shape without request_id:
{ "error": "Missing API Key", "code": "API_KEY_MISSING" }
Access-gate and rate-limit errors use the standard envelope. Branch on the
code field in both shapes; it is stable across releases.
Always branch on code, never on message: codes are stable across releases, messages are not. Include the request_id (also in the X-Request-Id header) when you contact support.
Common status codes
| Status | Meaning | What to do |
|---|---|---|
| 401 | The API key is missing, malformed or revoked. | Check the header format (Bearer sk_live_…) and that the key is active in the dashboard. |
| 403 | The key is valid but the account is restricted (banned, unverified email, inactive), or order polling was turned off for the account (ORDER_QUERY_NOT_AVAILABLE). |
Check your account in the dashboard; contact support if it is unexpected. |
| 409 | The order is already final, or cancellation is temporarily unavailable (CANCEL_DENIED_RETRY_LATER). |
Do not blindly retry writes. Wait, or use the final webhook event. |
| 412 | PRICE_CHANGED: the price is above your max_price_cents (beyond the 5% tolerance). |
Re-read the catalog, raise the cap or remove it, and retry. |
| 422 | INSUFFICIENT_BALANCE, SERVICE_NOT_AVAILABLE, CHANNEL_UNAVAILABLE and similar. |
Top up; retry later or try another country; pick another channel. |
| 429 | Rate limit, daily quota, or too many active orders. | Branch on code and honour Retry-After. See Rate limits. |
429 and 422 SERVICE_NOT_AVAILABLE are normal operating conditions. Back off and retry instead of showing raw codes to your users.
Every error code, by endpoint
| Endpoint | Status | Codes |
|---|---|---|
GET /orders |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /orders |
403 | ORDER_QUERY_NOT_AVAILABLE |
POST /orders |
400 | VALIDATION_ERROR, CURRENCY_MISMATCH |
POST /orders |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
POST /orders |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
POST /orders |
412 | PRICE_CHANGED |
POST /orders |
422 | INSUFFICIENT_BALANCE, WALLET_NOT_INITIALIZED, SERVICE_NOT_AVAILABLE, CHANNEL_UNAVAILABLE |
POST /orders |
429 | RATE_LIMITED, RATE_LIMITED_DAILY, TOO_MANY_ACTIVE_ORDERS |
GET /orders/{id} |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /orders/{id} |
403 | ORDER_QUERY_NOT_AVAILABLE |
GET /orders/{id} |
404 | ORDER_NOT_FOUND |
POST /orders/{id}/cancel |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
POST /orders/{id}/cancel |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
POST /orders/{id}/cancel |
404 | ORDER_NOT_FOUND |
POST /orders/{id}/cancel |
409 | CANCEL_DENIED_RETRY_LATER, ORDER_ALREADY_TERMINAL |
POST /orders/{id}/cancel |
422 | CANCEL_TOO_EARLY |
GET /balance |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /balance |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /catalog/services |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /catalog/services |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /catalog/countries |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /catalog/countries |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /catalog/prices |
400 | INVALID_REQUEST |
GET /catalog/prices |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /catalog/prices |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /catalog/prices |
404 | COUNTRY_NOT_FOUND |
GET /catalog/prices |
429 | PRICE_RATE_LIMITED |
GET /catalog/channels |
400 | INVALID_REQUEST |
GET /catalog/channels |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /catalog/channels |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /catalog/channels |
404 | COUNTRY_NOT_FOUND |
GET /catalog/channels |
429 | PRICE_RATE_LIMITED |
GET /rentals/plans |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /rentals/plans |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
POST /rentals/tos-accept |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
POST /rentals/tos-accept |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /rentals |
400 | VALIDATION_ERROR |
GET /rentals |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /rentals |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
POST /rentals |
400 | VALIDATION_ERROR |
POST /rentals |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
POST /rentals |
402 | INSUFFICIENT_BALANCE |
POST /rentals |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
POST /rentals |
404 | RENTAL_PLAN_NOT_FOUND |
POST /rentals |
412 | RENTAL_TOS_NOT_ACCEPTED, PRICE_CHANGED |
POST /rentals |
503 | RENTAL_NO_NUMBERS |
GET /rentals/sms |
400 | VALIDATION_ERROR |
GET /rentals/sms |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /rentals/sms |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /rentals/{id} |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /rentals/{id} |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /rentals/{id} |
404 | RENTAL_NOT_FOUND |
GET /rentals/{id}/sms |
401 | API_KEY_MISSING, API_KEY_INVALID_FORMAT, API_KEY_INVALID, API_KEY_REVOKED |
GET /rentals/{id}/sms |
403 | ACCOUNT_BANNED, EMAIL_NOT_VERIFIED, ACCOUNT_NOT_ACTIVE |
GET /rentals/{id}/sms |
404 | RENTAL_NOT_FOUND |