/
v3.0.11Get access

Odd Types

Union

Notation used to express the price of a selection. and tells the swarm which format the prices in the request are written in. The SDK maps each name to the numeric code

Possible values

Every literal this type accepts.

ValueDescription
'decimal'Total return per unit staked, stake included — 2.50 returns 2.50 for every 1 staked. Also called European odds.
'fractional'Profit as a fraction of the stake — 3/2 pays 3 profit for every 2 staked, plus the stake back. Common in the UK and Ireland.
'american'Moneyline notation. A positive price is the profit on a 100 stake (+150), a negative one the stake needed to win 100 (-200).
'hongKong'Profit per unit staked, stake excluded — 1.50 pays 1.50 profit plus the stake back. Equals the decimal price minus one.
'malay'Profit per unit staked when positive, and the stake needed to win one unit when negative. Always between -1 and 1.
'indo'Profit per unit staked when positive (1.5 wins 1.5 per unit), and the stake needed to win one unit when negative. American odds divided by 100.

Notes

The wire format is a numberThe swarm transports odd types as numeric codes, and the SDK converts between the name and the code for you in both directions — pass the string and you never have to touch a number. You will still see the codes in raw swarm payloads and in logs, so here is the full list: decimal 0, fractional 1, american 2, hongKong 3, malay 4 and indo 5. Unlike bet types these run in sequence with no gaps, in the same order as the table above, and decimal being 0 means an omitted odd type is read as decimal.
Was this page helpful?