Get user token
Request
URI: /getUserToken
Example usage: https://{callback_url}/getUserToken?{parameters}
The request is executed using the GET
method.
This method is used in for sport betting (if a long period of time has passed between the bet's placing and closing and the token has been expired). Recommended token time 5 minutes. Note, slots and live games do not use this method.
Request parameters
Name | Type | Required | Description |
---|---|---|---|
userId | string | Yes | The unique identifier of the user |
Response parameters
Name | Type | Required | Description |
---|---|---|---|
status | boolean | Yes | Response status code for Call back API Accepted values: true , false |
userId | string | Yes | The unique identifier of the user |
token | string | Yes | The token |
balance | decimal | Yes | Player's latest balance, at the time of the request completion Decimal format required |
errors | object | No | Description of errors in case status = false |
errors.code | number | No | Error code |
errors.error | string | No | Error description |
Example of a successful response
Response: /getUserToken
{
"status": true,
"userId": 4878,
"token": "XXXXXXXXXX",
"balance": 124000.55
}
Example of an unsuccessful response
Response: /getUserToken
{
"status": false,
"errors": {
"code": 400,
"error": "Description"
}
}