Callback Action: balance
The balance callback is sent to your callback URL as configured on Settings section in the backoffice.
This callback is triggered at the start of a game session and is used to retrieve the player’s current balance.
You must always return the player balance as an integer value in cents.
The call_id is a unique identifier sent with every callback and can be treated as a transaction reference.
⚠️ Important
- Your callback endpoint must always respond with HTTP status code
200 - Error handling is done only via the JSON body, not HTTP status codes
Requests
All callbacks are sent as GET requests to the callback URL configured on your API key.
Balance Callback Request
{
"username": "yourPlayerId9959",
"currency": "USD",
"action": "balance",
"call_id": "e2b801a1-e098-411c-8940-00514cb8070c",
"timestamp": "1696463571",
"key": "6c4e5fd14e796284b327bb4f9603aee4"
}Responses
The balance must always be returned as an integer in cents.
Example:
A player balance of$2.50must be returned as250.
All responses must return HTTP status code 200.
Successful Response
{
"error": 0,
"balance": 250
}Insufficient Balance
{
"error": 1,
"balance": 250
}Processing Error
(e.g. player not found or invalid signature)
{
"error": 2,
"balance": 0
}