Events API
Event View
GET
/v1/event/viewScore, stats, timeline and extra details of an event.
Parameters
Send every parameter in the query string, including token.
| Name | Type | Required | Description |
|---|---|---|---|
| token | string | Required | Your API token. |
| event_id | string | Required | Event id. Send up to 10 ids separated by commas: event_id=1,2,3. |
Request
Call https://api.odds-data-api.com/v1/event/view with your token. The examples read it from the ODDS_DATA_API_TOKEN environment variable.
curl "https://api.odds-data-api.com/v1/event/view?event_id=8204771&token=$ODDS_DATA_API_TOKEN"Response
JSON with success: 1 and results. Values are strings unless shown otherwise. See Response format and R-Pager.
application/json
{
"success": 1,
"results": [
{
"id": "8204771",
"sport_id": "1",
"time": "1789237200",
"time_status": "1",
"league": {
"id": "10041282",
"name": "England Premier League",
"cc": "gb"
},
"home": {
"id": "10204",
"name": "Brentford",
"image_id": null,
"cc": "gb"
},
"away": {
"id": "10218",
"name": "Everton",
"image_id": null,
"cc": "gb"
},
"ss": "2-1",
"scores": {
"1": {
"home": "1",
"away": "0"
},
"2": {
"home": "2",
"away": "1"
}
},
"timer": {
"tm": 67,
"ts": 12,
"tt": "1",
"ta": 0,
"md": 1
},
"bet365_id": "158204771",
"stats": {
"attacks": [
"88",
"61"
],
"dangerous_attacks": [
"44",
"29"
],
"possession_rt": [
"57",
"43"
],
"on_target": [
"6",
"3"
],
"off_target": [
"7",
"5"
],
"corners": [
"6",
"3"
],
"yellowcards": [
"2",
"1"
]
},
"extra": {
"home_manager": {
"id": "53463",
"name": "Tomás Duarte",
"cc": "pt"
},
"away_manager": {
"id": "1152",
"name": "Hugo Keller",
"cc": "de"
},
"referee": {
"id": "107059",
"name": "Chris Kavanagh",
"cc": "gb"
},
"stadium_data": {
"id": "606",
"name": "Gtech Community Stadium",
"city": "London",
"country": "England"
},
"round": "4"
},
"events": [
{
"id": "69731159",
"text": "15' - 1st Goal - (Brentford) -"
},
{
"id": "69731190",
"text": "58' - 3rd Goal - (Everton) -"
}
],
"has_lineup": 1,
"inplay_created_at": "1789236300",
"inplay_updated_at": "1789241232"
}
]
}Errors
A failed call returns success: 0 with an error code. This endpoint can return:
| error | Meaning |
|---|---|
| NOT_FOUND | 404 Not Found. |
| AUTHORIZE_FAILED | Token is not provided or is incorrect. |
| TOO_MANY_REQUESTS | API rate limit exceeded. See X-RateLimit-Reset. |
| PERMISSION_DENIED | Your plan does not include this call. Contact support if this is wrong. |
| PARAM_REQUIRED | A required param is missing. Check error_detail. |
| PARAM_INVALID | A param is invalid. Check error_detail. |
Failed call · application/json
{
"success": 0,
"error": "PARAM_REQUIRED",
"error_detail": "event_id"
}Like every endpoint, it can also return INTERNAL_SERVER_ERROR, METHOD_NOT_ALLOWED and UNDER_MAINTENANCE. See R-Errors.
Try it
GET
https://api.odds-data-api.com/v1/event/view?event_id=8204771&token=YOUR-TOKEN- event_id
- 8204771
- token
- YOUR-TOKEN (from the dashboard)
Requests run with your own token and count toward your hourly limit.
