Sports
Sport keys and the leagues delivered for each.
Sports group leagues and decide which markets apply. Team sports use home and away; individual sports use competitor_1 and competitor_2.
| Sport | Key | Leagues with pages |
|---|---|---|
| Australian football | australian_football | 2 |
| Tennis | tennis | 2 |
| Soccer | soccer | 7 |
| Baseball | baseball | 1 |
| Basketball | basketball | 2 |
| American football | american_football | 2 |
| Ice hockey | ice_hockey | 1 |
| Rugby league | rugby_league | 3 |
| Mixed martial arts | mma | 1 |
curl -sS "https://api.sockodds.com/v1/sports" \
-H "Authorization: Bearer $SOCKODDS_API_KEY"const response = await fetch("https://api.sockodds.com/v1/sports", {
headers: { Authorization: `Bearer ${process.env.SOCKODDS_API_KEY}` },
});
console.log(JSON.stringify(await response.json(), null, 2));import json, os, urllib.request
request = urllib.request.Request(
"https://api.sockodds.com/v1/sports",
headers={"Authorization": "Bearer " + os.environ["SOCKODDS_API_KEY"]},
)
with urllib.request.urlopen(request) as response:
print(json.dumps(json.load(response), indent=2))Response from a local copy of the API with invented test prices
{
"data": [
{
"key": "australian_football",
"name": "Australian football",
"participants": "teams"
},
{
"key": "rugby_league",
"name": "Rugby league",
"participants": "teams"
},
{
"key": "rugby_union",
"name": "Rugby union",
"participants": "teams"
},
{
"key": "soccer",
"name": "Soccer",
"participants": "teams"
},
{
"key": "basketball",
"name": "Basketball",
"participants": "teams"
},
{
"key": "american_football",
"name": "American football",
"participants": "teams"
},
{
"key": "baseball",
"name": "Baseball",
"participants": "teams"
},
{
"key": "ice_hockey",
"name": "Ice hockey",
"participants": "teams"
},
{
"key": "tennis",
"name": "Tennis",
"participants": "competitors"
},
{
"key": "mma",
"name": "Mixed martial arts",
"participants": "competitors"
},
{
"key": "cricket",
"name": "Cricket",
"participants": "teams"
},
{
"key": "motorsport",
"name": "Motorsport",
"participants": "competitors"
},
{
"key": "esports",
"name": "Esports",
"participants": "teams"
}
],
"meta": {
"count": 13,
"cursor": null
},
"links": {
"next": null
}
}