Cash-out Build Followed by Cash-out Placement
This example shows a complete managed cash-out sequence:
the client requests a build;
MTS returns a margin-adjusted cash-out value;
the bettor accepts the value;
the client submits placement using the original ticket identity;
MTS accepts the placement.
The cashoutId and correlationId values are client-defined and are unique per request. The placement request uses the original ticketId and ticketSignature. It does not reuse the build cashoutId or the build response signature.
Cash-out Build Request
{
"operatorId": 9985,
"content": {
"type": "cashout-build",
"cashout": {
"type": "cashout",
"cashoutId": "build-001",
"details": {
"type": "ticket",
"ticketId": "Ticket_12345",
"ticketSignature": "ORIGINAL_TICKET_SIGNATURE",
"code": 101,
"payout": [
{
"type": "cash",
"currency": "EUR",
"amount": "8.50"
}
]
}
}
},
"correlationId": "build-correlation-001",
"timestampUtc": 1770000000000,
"operation": "cashout-build",
"version": "3.0"
}Cash-out Build Response
{
"content": {
"type": "cashout-build-reply",
"cashoutId": "build-001",
"signature": "BUILD_RESPONSE_SIGNATURE",
"status": "accepted",
"ticketId": "Ticket_12345",
"code": 0,
"message": "Transaction processed",
"cashout": {
"cashoutType": "ticket",
"cashoutId": "build-001",
"maxPayout": [
{
"type": "cash",
"currency": "EUR",
"amount": "15.80",
"source": "cash",
"stakeOrigin": "cash"
}
],
"fairCashout": [
{
"type": "cash",
"currency": "EUR",
"amount": "10.02",
"source": "cash",
"stakeOrigin": "cash"
}
],
"cashout": [
{
"type": "cash",
"currency": "EUR",
"amount": "8.89",
"source": "cash",
"stakeOrigin": "cash"
}
]
}
},
"correlationId": "build-correlation-001",
"timestampUtc": 1770000001000,
"operation": "cashout-build",
"version": "3.0"
}The client displays the margin-adjusted value of 8.89 EUR. The bettor accepts the offer.
Cash-out Placement Request
{
"operatorId": 9985,
"content": {
"type": "cashout-placement",
"cashout": {
"type": "cashout",
"cashoutId": "placement-001",
"details": {
"type": "ticket",
"ticketId": "Ticket_12345",
"ticketSignature": "ORIGINAL_TICKET_SIGNATURE",
"code": 101,
"payout": [
{
"type": "cash",
"currency": "EUR",
"amount": "8.89"
}
]
}
}
},
"correlationId": "placement-correlation-001",
"timestampUtc": 1770000002000,
"operation": "cashout-placement",
"version": "3.0"
}After receiving the accepted placement response, the client can finalise the local payout. The client must not send an additional cashout-inform request for this cash-out.
Last updated
Was this helpful?