Superbet

POST `/be/tickets/reserve` endpoint

Reserve superbet ticket.

Request fields:

Attribute
Data Type
Description

operator

string

Name of the operator as registered on the system

token

string

Player identification token

price

integer

Ticket price. Should be in integer format (cents). For example, for price 35.00 the value will be 3500

currency

string

atag

string or null

Optional affiliate Tag or Affiliate ID. If parameter is present then it is added to the ticket_reserve PAM API call.

source

string

type

string

event

integer

Event id

bets

list of integers

Each element is event bet id

Sample request to reserve superbet ticket:

{
    "operator": "site",
    "token": "sGhx12skwrXsukbZmWh7bkCC9YPEzYQKtKSe9EfCth3Q",
    "price": 2000,
    "currency": "KES",
    "atag": "affiliate-1",
    "source": "mobile",
    "type": "superbet",
    "event": 100001,
    "bets": [101, 102, 103, 104, 105, 106]
}

Response fields:

Attribute
Data Type
Description

id

string

Ticket id

code

string

Ticket code

price

integer

Ticket price. Should be in integer format (cents). For example, for price 35.00 the value will be 3500

stake

integer

Ticket amount. Should be in integer format (cents). For example, for stake 30.45 the value should be 3045

gross_payout

integer

Ticket gross payout. Should be in integer format (cents). Will always be 0

net_payout

integer

Ticket net payout. Should be in integer format (cents). Will always be 0

wht_amount

integer

Player withholding tax amount. Should be in integer format (cents). Will always be 0

wht

integer

Player withholding tax percentage. For example, for withholding tax percentage 20.0% the value should be 20.0

ext_amount

integer

Ticket exercise tax amount. Should be in integer format (cents). For example, for exercise tax amount 1.25 the value will be 125

ext

float

Ticket exercise tax percentage. For example, for exercise tax percentage 12.5% the value should be 12.5

ext_type

string

currency

string

status

string

result

string

approved

bool

source

string

type

string

atag

string

Optional affiliate Tag or Affiliate ID. If parameter is present then it is added to the ticket_reserve PAM API call.

user_id

string

User ID from PAM

created

string

Ticket created datetime, UTC. Format - 2024-01-28T14:33:01.000000

operator_time_created

string

Ticket created datetime, operator timezone. Format - 2024-01-28T14:33:01.000000

updated

string

Ticket updated datetime, UTC. Format - 2024-01-28T14:33:01.000000

operator_time_updated

string

Ticket updated datetime, operator timezone. Format - 2024-01-28T14:33:01.000000

Sample response (status=200) to superbet ticket:

{
    "id": "66902734beba20ff2df5c79f",
    "code": "DEC4C0",
    "price": 1000,
    "stake": 889,
    "gross_payout": 0,
    "net_payout": 0,
    "wht_amount": 0,
    "wht": 10.0,
    "ext_amount": 111,
    "ext": 12.5,
    "ext_type": "inclusive",
    "currency": "USD",
    "status": "reserved",
    "result": "pending",
    "approved": true,
    "source": "desktop",
    "type": "superbet",
    "atag": "atag_value",
    "user_id": "token_i",
    "created": "2024-07-11T18:40:52.995000",
    "operator_time_created": "2024-07-11T20:40:52.995000",
    "updated": "2024-07-11T18:40:53.013000",
    "operator_time_updated": "2024-07-11T20:40:53.013000"
}

Response status codes:

Status Code
Interpretation

200

OK - Everything worked as expected

400

403

Forbidden. You do not have access for such request

422

Validation Error. Please check response body for more details

Error response (status=400):

{
    "code": 103,
    "message": "Event with `{event-id}` identifier is not found"
}

Error response (status=400):

{
    "code": 105,
    "message": "Team with `{team-id}` identifier is not found"
}

Error response (status=400):

{
    "code": 106,
    "message": "Market for bet with `{market-id}` identifier is not found"
}

Error response (status=400):

{
    "code": 107,
    "message": "Event with `{event-id}` identifier is not available for play because it has already started"
}

Error response (status=400):

{
    "code": 111,
    "message": "Duplicate key for code generation"
}

Error response (status=400):

{
    "code": 112,
    "message": "Operator with `{operator-id}` name is not found"
}

Error response (status=400):

{
    "code": 114,
    "message": "No webhook url for operator with `{operator-id}` name"
}

Error response (status=400):

{
    "code": 115,
    "message": "Operators in request body and in request header are not identical"
}

Error response (status=400):

{
    "code": 116,
    "message": "Market with `{market-id}` code is not allowed"
}

Last updated