FixturesEndpoint 7 of 116
Statistics
GET
https://api.datasportsapi.com/
- Plan
- All plans
- Auth
Bearer dsa_live_…- Parameters
- 1 required · 0 optional
- Returns
Statistics
Team statistics for the match, organised by period and by category.
Worth knowing
- Coverage is graded the same way as for lineups and grows richer as the match goes on: a lower-tier fixture might offer nothing but cards, whereas a top league delivers every group.
- Statistic keys form one shared vocabulary across all sports (totalShots, shotsOnGoal, passes, fouls, …; the reference’s Statistic keys lists every key per sport), and group keys follow a fixed table for each sport.
- In American football, the team-level passingNetYards and passingYardsPerAttempt are gross figures from the source (sacks are not subtracted), whereas a player’s passingNetYards in the lineups is net.
- A fixture without statistics (yet — before kick-off, for instance) returns 200 with { "periods": [] }; you only get 404 for an id that does not exist.
- Data is refreshed approximately every 30 seconds during a live match.
01Parameters
idpathRequiredfixture id issued by DataSportsAPI, a positive integer
02Request
The same call from the command line and each SDK. The SDK lines assume a client created with your key; left out, it is read from DATASPORTSAPI_API_KEY. Installing a client: SDKs & CLI.
curl -H "Authorization: Bearer dsa_live_…" \
"https://api.datasportsapi.com/v2/fixtures/{id}/statistics"03Response
The top-level keys of the JSON body. Each object links to its full shape in the data reference.
dataStatistics
ObjectsStatistics
Example response
9 lines
{ "data": { "periods": [ { "period": "all", "groups": [
{ "key": "matchOverview", "name": "Match overview", "items": [
{ "key": "ballPossession", "name": "Ball possession", "kind": "value", "higherIs": "better",
"home": { "display": "26%", "value": 26, "total": null }, "away": { "display": "74%", "value": 74, "total": null } },
{ "key": "fouls", "name": "Fouls", "kind": "value", "higherIs": "worse",
"home": { "display": "13", "value": 13, "total": null }, "away": { "display": "11", "value": 11, "total": null } },
{ "key": "accurateLongBalls", "name": "Long balls", "kind": "ratio", "higherIs": "better",
"home": { "display": "30/64 (47%)", "value": 30, "total": 64 }, "away": { … } }, … ] } ] },
{ "period": "period1", "groups": [ … ] } ] } }04Errors
Nothing specific to this endpoint: only the account-wide errors below apply.
Any key can also meet401
unauthorized429rate_limited429quota_exceeded500internal_errorEvery error code