cancel
Used to cancel user’s bet. Buffalo game will trigger this API when something went wrong between operator server and buffalo game server. For example, credit request time out on the operator server
- Operator should always accept the cancel request even the sid is expired to avoid the reconciliation issues
- The operator need to validate the user information is valid
- user id
- currency
- The operator can get detail by the id and session in the game object
Request Properties
- Name
userId- Type
- string
- Description
Player’s ID which is sent by operator in Game Launch request (player.userId) Game Launch
- Name
sid- Type
- string
- Description
Player’s session ID which is sent by operator in the Game Launch request (player.sid) Game Launch
- Name
currency- Type
- object
- Description
Currency code (ISO 4217 3 letter code) of player’s session currency
- Name
game- Type
- object
- Description
Object containing game details
- Name
game.id- Type
- string(64)
- Description
Unique game round id. Operator can use this id and type to query the detail of game.
- Name
game.type- Type
- string
- Description
The game type value (e.g. “plinko”, “minesweeper”); (see Game types), Operator can use this id and type to query the detail of game.
- Name
game.session- Type
- string
- Description
The user's session id in the buffalo game. Operator can query the information by this session id if need.
- Name
transaction- Type
- object
- Description
Object containing transaction details
- Name
transaction.id- Type
- string(64)
- Description
The unique identifier of transaction (e.g: used to avoid duplicate bets and other validations)
- Name
transaction.refId- Type
- string(64)
- Description
Reference identifier for transaction, to be able to link (correlate) and/or validate CreditRequest/CancelRequest to appropriate DebitRequest.
- Name
transaction.amount- Type
- decimal
- Description
Amount of transaction in player’s session currency, rounded to 6 decimal places
- Name
uuid- Type
- string
- Description
Unique request id, that identifies DebitRequest
Response Properties
- Name
status- Type
- string
- Description
The response status. Please refer to the status page. Status Code Page
- Name
balance- Type
- string
- Description
Player’s balance
- Name
bonus- Type
- object
- Description
Player’s remaining balance. Operator can ignore this one if operator didn't have this information
- Name
uuid- Type
- string
- Description
Unique request id, that should be the same as the request
Cancel request
Request
{
"sid": "sid-parameter-from-UserAuthentication-call",
"userId": "euID-parameter-from-UserAuthentication-call",
"currency": "EUR",
"game": {
"id": "7kfwqku4jb4mtas1n4k4irqa",
"session": "as123u4jb4mtas1n4k4irqa",
"type": "plinko",
},
"transaction":{
"id": "9AotBIvi23",
"refId": "1459zzz",
"amount": 1.556179
},
"uuid": "ce186440-ed92-11e3-ac10-0800200c9a66"
}
Response
{
"status":"OK",
"balance":999.35,
"bonus":1.00,
"uuid":"ce186440-ed92-11e3-ac10-0800200c9a66"
}