Skip to main content

Error Handling

The API uses standard HTTP status codes and returns consistent error objects.

Response Format

All responses follow this structure:
{
  "success": true,
  "data": { ... },
  "message": "Success"
}
Error responses:
{
  "success": false,
  "error": {
    "code": "INVALID_SIGNATURE",
    "message": "The provided signature is invalid."
  }
}

Error Codes

CodeHTTP StatusDescription
INVALID_API_KEY401API key is invalid or not found
INVALID_SIGNATURE401Signature verification failed
INSUFFICIENT_BALANCE402Not enough deposit balance
INVALID_PRODUCT400Product SKU not found or inactive
INVALID_CUSTOMER_NO400Customer number / game ID is invalid
DUPLICATE_REF_ID409Reference ID has already been used
ORDER_NOT_FOUND404Order with given ref_id not found
PRODUCT_OUT_OF_STOCK400Product is currently out of stock
RATE_LIMIT_EXCEEDED429Too many requests, please slow down
IP_NOT_WHITELISTED403Request IP is not in your whitelist
INTERNAL_ERROR500Server error, please try again later
MAINTENANCE503System is under maintenance

Best Practices

Always check the success field in the response before processing the data.
  1. Retry with exponential backoff for 5xx errors
  2. Don’t retry 4xx errors — fix the request first
  3. Log all error responses for debugging
  4. Use unique ref_id for every order to prevent duplicates