API structure modification #98
martinkramerLS
started this conversation in
General
Replies: 1 comment
-
We would suggest you to transform the market data json from our format to the one you desire (i.e. market name as a key value pair of We provide a list of all our markets, as well as market names in this Github gist. So you could add a parsing step to read the input json, and map the market key to market value you desire. For example for "soccer.asian_handicap": {
"Name": "Asian Handicap", Hope this helps! Cheers, |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
"markets": { "soccer.asian_handicap": { "submarkets": { "period=ft": { "sequence": "132", "selections": [ { "outcome": "home", "params": "handicap=-0.5", "price": 2.65, "minStake": 0.1, "maxStake": 87.30869, "probability": 0.346, "status": "SELECTION_ENABLED", "side": "BACK" }, { "outcome": "away", "params": "handicap=-0.5", "price": 1.4, "minStake": 0.1, "maxStake": 360.15, "probability": 0.654, "status": "SELECTION_ENABLED", "side": "BACK" }, { "outcome": "home", "params": "handicap=-1.5", "price": 7, "minStake": 0.1, "maxStake": 24.01, "probability": 0.132, "status": "SELECTION_ENABLED", "side": "BACK" }, { "outcome": "away", "params": "handicap=-1.5", "price": 1.06, "minStake": 0.1, "maxStake": 2401, "probability": 0.868, "status": "SELECTION_ENABLED", "side": "BACK" }, { "outcome": "home", "params": "handicap=0.5", "price": 1.14, "minStake": 0.1, "maxStake": 1029, "probability": 0.808, "status": "SELECTION_ENABLED", "side": "BACK" }, { "outcome": "away", "params": "handicap=0.5", "price": 4.8, "minStake": 0.1, "maxStake": 37.91032, "probability": 0.192, "status": "SELECTION_ENABLED", "side": "BACK" } ] } } }, }
The structure we've found.
{ "market": "Asian Handicap", "period": "ft", "handicap": "-0,5", "selections": [ { "outcome": "home", "price": 2.65, "minStake": 0.1, "maxStake": 87.30869, "probability": 0.346, "status": "SELECTION_ENABLED", "side": "BACK" }, { "outcome": "away", "price": 1.4, "minStake": 0.1, "maxStake": 360.15, "probability": 0.654, "status": "SELECTION_ENABLED", "side": "BACK" } ] }
And this would be perfect to have. To have the market name in a "value" and not in an "attribute / key"
Beta Was this translation helpful? Give feedback.
All reactions