Error Handling
Error response formats and codes.
Error Response Format
All errors are returned with a consistent JSON body:
{
"error": {
"message": "Not enough money to make a bet",
"code": "INSUFFICIENT_FUNDS"
}
}
Error Object Fields
| Field | Type | Description |
|---|---|---|
| error.message | string | Human-readable description of the error |
| error.code | string | Machine-readable error code. Use this for error handling logic |
Wallet API Error Codes
Error Codes
| Code | Description |
|---|---|
| PLAYER_UNAUTHORIZED | Wrong authorization bearer token |
| SERVER_UNAUTHORIZED | Wrong authorization HMAC hash |
| SESSION_EXPIRED | Player's session has expired |
| LOSS_LIMIT | Player's loss limit exceeded |
| INSUFFICIENT_FUNDS | Not enough money to place the bet |
| TRANSACTION_NOT_FOUND | Transaction you're trying to cancel was not found |
| TRANSACTION_FAILED | Transaction was not processed |
| INTERNAL_ERROR | Internal server error |
| CANCEL_REQUIRED | Cancel request reuired to rollback bet transaction |
Free Bets API Error Codes
Error Codes
| Code | Description |
|---|---|
| VALIDATION_ERROR | Request validation error (missing or invalid fields) |
| FREE_BETS_NOT_FOUND | Free bets campaign you're trying to cancel was not found |
| INTERNAL_ERROR | Internal server error |
General error codes for Game Launch, Free Bets and Extra API's
Error Codes
| Code | Description |
|---|---|
| SERVER_ERROR | Contact tech support if you get it |
| APPLICATION_ERROR | Contact tech support if you get it |