Skip to content

Livematches in play

Demo: Matchboard, opens in a new tab
Docs v2

Leagues

Top match performances

GET

/v2/leagues/{id}/top-performances

Pro and up

View as MarkdownTry in Playground →

Record individual match performances in a league season. For each statistic — in football goals, assists, rating, xG, key passes, saves, top speed, distance covered, …; in basketball points, rebounds, assists, …; in ice hockey points, hits, saves, … — you get up to 10 players, each with the value and the fixture in which it was achieved. Pass category to limit the response to one statistic.

category takes a per-match statistic key, as found in a lineup player’s statistics (goals, assists, rating, keyPass, successfulDribbles, topSpeed, kilometersCovered, …) — not a season-leaderboard key such as averageRating. Entries keep our data source’s ranking with the best at the top — and for missed penalties, turnovers and errors leading to a goal, the best is the highest count. fixture contains the complete Fixture (teams, score, start). If type is omitted, the season’s default applies (regularSeason for the NBA, NHL, …). These lists exist for football, basketball and ice hockey; a league that has none returns an empty array. Updated daily.

Parameters

id

pathrequired

league id issued by DataSportsAPI, a positive integer

season

queryrequired

season id, as listed by /v2/leagues/{id}/seasons

type

query

overall | home | away | regularSeason | playoffs. When omitted, the season’s own default applies: overall if the season has it (football), otherwise regularSeason (NBA, NHL, …); meta.type reports the value used

category

query

restricts the response to a single statistic key from the list (e.g. topSpeed)

Response

meta
season, type (the value actually applied), category (null when every statistic is included), count (how many categories)
errors
400 bad_request — one of: season missing or invalid; type outside overall, home, away, regularSeason, playoffs; category malformed404 not_found — the season id does not belong to this league

Any /v2 call can also come back with one of the common errors.

curl -H "Authorization: Bearer sk_live_…" \
    "https://api.datasportsapi.com/v2/leagues/{id}/top-performances?season=…"
Example
{ "data": [ { "category": "rating", "performances": [
      { "player": { "id": 3802, "name": "Bruno Fernandes", "image": "…", … },
        "fixture": { "id": 701102, "home": { "name": "Manchester United", … }, "away": { "name": "Ipswich Town", … },
                     "homeScore": { "current": 5, … }, "awayScore": { "current": 2, … }, "status": { "type": "finished", … }, … },
        "value": 10 }, … ] },
    { "category": "topSpeed", "performances": [ { "player": { "name": "Harvey Barnes", … }, "fixture": { … }, "value": 36.207 }, … ] }, … ],
  "meta": { "season": 200386, "type": "overall", "category": null, "count": 21 } }