# Sports Data API — live scores, fixtures, standings, teams, players & odds (ESPN + SofaScore)

> Live and final scores for a league — pass a date (YYYYMMDD) or range to get scores for any day; omit it for today/in-play games.
> ReefAPI engine `sports-data` · 50 endpoints · clean JSON, no scraping or browsers to manage.

## How to call
- **Endpoint:** `POST https://api.reefapi.com/sports-data/v1/<action>` with a JSON body.
- **Auth:** header `x-api-key: <YOUR_REEFAPI_KEY>` — create one free (1,000 credits, no card): https://reefapi.com/signup
- **Response (every call):** `{ ok: boolean, data: ..., meta: { record_count, credits, ... }, error: { code, message } }` — branch on `ok`. Failed or blocked calls are free.
- **One key + one shared credit pool** across every ReefAPI API. Per-call credits are listed on each endpoint below.
- **Use it from an AI agent (MCP):** connect `https://api.reefapi.com/mcp` (remote streamable-http, `Authorization: Bearer <key>`) and your assistant can call these actions directly.

## Endpoints

### POST /sports-data/v1/scores — 1 credit
Live and final scores for a league — pass a date (YYYYMMDD) or range to get scores for any day; omit it for today/in-play games.

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `date` (string, optional) — Date filter, ESPN format YYYYMMDD (or a range 'YYYYMMDD-YYYYMMDD'). Omit for today / live.

**Returns:** events[] (scoreboard: teams, score, status, competition), count

**Example request body:**
```json
{
  "sport": "soccer",
  "league": "eng.1",
  "dates": "20260301-20260331"
}
```

### POST /sports-data/v1/fixtures — 1 credit
Upcoming fixtures and the match schedule for a league, by date or date range (same event shape as scores).

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `date` (string, optional) — Date filter, ESPN format YYYYMMDD (or a range 'YYYYMMDD-YYYYMMDD'). Omit for today / live.

**Returns:** events[] (schedule by date/range), count

**Example request body:**
```json
{
  "sport": "soccer",
  "league": "eng.1",
  "dates": "20260301-20260331"
}
```

### POST /sports-data/v1/standings — 1 credit
Full league table / standings with wins, losses, points and per-team stats (soccer leagues accept a season year).

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `season` (integer, optional) — Season year (soccer standings need it; default current season).

**Returns:** league, season, standings[]{rank,team,played,wins,draws,losses,points}, count

**Example request body:**
```json
{
  "sport": "basketball",
  "league": "nba"
}
```

### POST /sports-data/v1/team — 1 credit
Every team in a league, or one team's detail (record, next game, logo) when you pass a team_id.

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `team_id` (string, optional) — ESPN team id — get it from the `team` action's teams[].team_id for the same sport/league (e.g. 13 = NBA Denver Nuggets).

**Returns:** teams[] for the league, OR a single team{} when team_id is given

**Example request body:**
```json
{
  "sport": "basketball",
  "league": "nba"
}
```

### POST /sports-data/v1/roster — 1 credit
A team's full roster / squad with jersey, position, age, height, weight and nationality for each player.

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `team_id` (string, required) — ESPN team id — get it from the `team` action's teams[].team_id for the same sport/league (e.g. 13 = NBA Denver Nuggets).

**Returns:** roster{} — squad with player fields, player_count

**Example request body:**
```json
{
  "sport": "basketball",
  "league": "nba",
  "team_id": "13"
}
```

### POST /sports-data/v1/summary — 2 credits
Full match summary: boxscore, per-player stats, lineups, play-by-play count, head-to-head, win probability and odds.

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** boxscore + player stats + play-by-play + H2H + win-probability + lineups + pickcenter

**Example request body:**
```json
{
  "sport": "baseball",
  "league": "mlb",
  "event_id": "401815591"
}
```

### POST /sports-data/v1/odds — 1 credit
Betting odds (moneyline, spread, over/under) — for one game by event_id, or every scheduled game in the league that has odds.

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `event_id` (string, optional) — Optional ESPN event id: returns the closing line for that one game; omit to list every scheduled game that currently has odds.
- `date` (string, optional) — Date filter, ESPN format YYYYMMDD (or a range 'YYYYMMDD-YYYYMMDD'). Omit for today / live.

**Returns:** events_with_odds[] (or odds[] for one event_id): moneyline/spread/total, count

**Example request body:**
```json
{
  "sport": "baseball",
  "league": "mlb",
  "event_id": "401815591"
}
```

### POST /sports-data/v1/news — 1 credit
Latest news headlines and articles for a league.

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]

**Returns:** league, articles[] (headlines), count

**Example request body:**
```json
{
  "sport": "basketball",
  "league": "nba"
}
```

### POST /sports-data/v1/search — 1 credit
Look up a team or player by name across all sports (returns ids, badges, league, country) — start here when you only have a name.

**Parameters:**
- `query` (string, required) — Search text for a team/player/tournament/manager/referee.
- `type` (enum, optional, default "team") — What to look up in the (thesportsdb) search. Defaults to team. [one of: team, player]

**Returns:** type, query, results[] (teams or players from thesportsdb), count

**Example request body:**
```json
{
  "query": "Arsenal",
  "type": "team"
}
```

### POST /sports-data/v1/injuries — 1 credit
Current injury report for a league, grouped by team, with each player's status and detail.

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]

**Returns:** league, teams[]{team, injuries[]{player,position,status,date,detail}}, count

**Example request body:**
```json
{
  "sport": "basketball",
  "league": "nba"
}
```

### POST /sports-data/v1/team_schedule — 1 credit
One team's full season schedule and results (every game the team plays, unlike league-wide fixtures).

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]
- `team_id` (string, required) — ESPN team id — get it from the `team` action's teams[].team_id for the same sport/league (e.g. 13 = NBA Denver Nuggets).
- `season` (integer, optional) — Season year (soccer standings need it; default current season).

**Returns:** team, season, events[] (same shape as scores/fixtures), count

**Example request body:**
```json
{
  "sport": "basketball",
  "league": "nba",
  "team_id": "13"
}
```

### POST /sports-data/v1/conferences — 1 credit
A league's conference / division structure (the directory of groups and sub-groups, e.g. college conferences).

**Parameters:**
- `sport` (enum, required) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `league` (enum, required) — League key (e.g. nba, nfl, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, uefa.champions, usa.1) or a raw ESPN segment ('bra.1') / cricket series id. SofaScore actions also accept a numeric tournament id. [one of: nba, wnba, ncaam, ncaaw, nfl, ncaaf, mlb, college-baseball, nhl, atp, wta, eng.1, eng.2, esp.1, ita.1, ger.1, fra.1, ned.1, por.1, usa.1, mex.1, bra.1, uefa.champions, uefa.europa, fifa.world, ipl, bbl, sheffield-shield, county-championship, cricket-world-cup]

**Returns:** league, groups[]{name,abbreviation,is_conference,children[] (nested conferences/divisions)}, count

**Example request body:**
```json
{
  "sport": "basketball",
  "league": "ncaam"
}
```

### POST /sports-data/v1/leagues — 0 credits
Directory of every supported league/competition (key, name, sport) — call this first to discover the league keys the other actions take.

**Parameters:**
- `sport` (enum, optional) — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]

**Returns:** sport, leagues[]{league (key to pass to other actions), name, sport}, count

### POST /sports-data/v1/entity_search — 1 credit
search players/teams/tournaments/managers/referees → SofaScore ids

**Parameters:**
- `query` (string, required) — Search text for a team/player/tournament/manager/referee.

**Returns:** query, results[]{type,id,name,slug,sport,country}, count

**Example request body:**
```json
{
  "query": "Haaland"
}
```

### POST /sports-data/v1/live_events — 1 credit
all in-play events for a sport

**Parameters:**
- `sport` (enum, required, default "football") — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]

**Returns:** sport, events[] (in-play, unified brief), count

**Example request body:**
```json
{
  "sport": "soccer"
}
```

### POST /sports-data/v1/scheduled_events — 1 credit
all scheduled events for a sport on a date

**Parameters:**
- `sport` (enum, required, default "football") — Sport family (ESPN path). Required with a raw league segment; a known league key (e.g. 'nba') can resolve the sport on its own. [one of: baseball, basketball, cricket, football, hockey, soccer, tennis]
- `date` (string, required) — Date filter, ESPN format YYYYMMDD (or a range 'YYYYMMDD-YYYYMMDD'). Omit for today / live.

**Returns:** sport, date, events[] (scheduled, unified brief), count

### POST /sports-data/v1/tournament_seasons — 0 credits
Every season available for a competition (season id + year) — use the id to scope season-specific calls.

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.

**Returns:** unique_tournament_id, seasons[]{season_id,name,year}, count

**Example request body:**
```json
{
  "league": "eng.1"
}
```

### POST /sports-data/v1/match_statistics — 2 credits
detailed match stats (possession/shots/xG)

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** per-period stat groups (possession/shots/xG/...) keyed by period

**Example request body:**
```json
{
  "event_id": "14025079"
}
```

### POST /sports-data/v1/match_lineups — 2 credits
lineups + per-player ratings & stats

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** confirmed, home/away{formation, players[]{rating,minutes,goals,...}, missing[]}

**Example request body:**
```json
{
  "event_id": "14025079"
}
```

### POST /sports-data/v1/match_momentum — 1 credit
attack-momentum graph

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** momentum[]{minute,value}, period_minutes, periods

**Example request body:**
```json
{
  "event_id": "14025079"
}
```

### POST /sports-data/v1/match_incidents — 1 credit
goal/card/sub timeline

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** event_id, items[] (goal/card/sub timeline), count

**Example request body:**
```json
{
  "event_id": "14025079"
}
```

### POST /sports-data/v1/match_best_players — 1 credit
best player per team

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** home/away best player {name,rating,label}

**Example request body:**
```json
{
  "event_id": "401815591"
}
```

### POST /sports-data/v1/match_h2h — 1 credit
head-to-head duel record

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** team_duel{home_wins,away_wins,draws}, manager_duel

**Example request body:**
```json
{
  "event_id": "14025079"
}
```

### POST /sports-data/v1/match_managers — 1 credit
both managers for a match

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** home/away manager {manager_id,name}

**Example request body:**
```json
{
  "event_id": "401815591"
}
```

### POST /sports-data/v1/match_odds — 2 credits
multi-market odds for a match

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** event_id, markets[]{market,choices[]{name,odds,...}}

**Example request body:**
```json
{
  "event_id": "401815591"
}
```

### POST /sports-data/v1/match_player_heatmap — 1 credit
a player's touch heatmap in a match

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.

**Returns:** points[]{x,y}, count (a player's touch heatmap in the match)

**Example request body:**
```json
{
  "event_id": "401815591",
  "player_id": "839956"
}
```

### POST /sports-data/v1/match_player_shotmap — 1 credit
a player's shotmap in a match

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.

**Returns:** shots[]{player,shot_type,x,y,xg,minute}

**Example request body:**
```json
{
  "event_id": "401815591",
  "player_id": "839956"
}
```

### POST /sports-data/v1/match_average_positions — 1 credit
average player positions on the pitch

**Parameters:**
- `event_id` (string, required) — ESPN event/game id — take it from the `event_id` of any scores, fixtures or team_schedule result for the same sport/league.

**Returns:** home/away[]{player,avg_x,avg_y,touches}

**Example request body:**
```json
{
  "event_id": "14025079"
}
```

### POST /sports-data/v1/player — 1 credit
Player profile: current team, position, market value, preferred foot, height, date of birth and contract — by SofaScore player id.

**Parameters:**
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.

**Returns:** player profile {name,team,position,value,foot,contract,...}

**Example request body:**
```json
{
  "player_id": "839956"
}
```

### POST /sports-data/v1/player_season_stats — 2 credits
player's season statistics in a league

**Parameters:**
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `type` (enum, optional, default "overall") — Stat split. Other SofaScore split keys are accepted but a wrong one 404s. [one of: overall, home, away]
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** team, statistics{} for the season

**Example request body:**
```json
{
  "player_id": "839956",
  "league": "eng.1",
  "season_id": "61627"
}
```

### POST /sports-data/v1/player_heatmap — 1 credit
player's season heatmap

**Parameters:**
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** points[]{x,y}, count (season heatmap)

**Example request body:**
```json
{
  "player_id": "839956",
  "league": "eng.1"
}
```

### POST /sports-data/v1/player_attributes — 1 credit
player attribute radar (att/tech/tac/def/cre)

**Parameters:**
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.

**Returns:** player + position_average attribute radars

**Example request body:**
```json
{
  "player_id": "839956"
}
```

### POST /sports-data/v1/player_transfers — 1 credit
A player's full transfer history (from/to club, fee, date) by SofaScore player id.

**Parameters:**
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.

**Returns:** transfers[]{from,to,fee,date}, count

**Example request body:**
```json
{
  "player_id": "839956"
}
```

### POST /sports-data/v1/player_recent — 1 credit
player's recent matches

**Parameters:**
- `player_id` (string, required) — SofaScore player id (e.g. 839956 = Erling Haaland). Resolve unknown players from a SofaScore player URL or a team_squad result.

**Returns:** player_id, recent_matches[] (unified brief), count

**Example request body:**
```json
{
  "player_id": "839956"
}
```

### POST /sports-data/v1/team_details — 1 credit
Team profile: manager, venue, founding year and recent pregame form — by SofaScore team id.

**Parameters:**
- `team_id` (string, required) — SofaScore team id (NOT the ESPN id) — e.g. 17 = Manchester City, 42 = Arsenal. Resolve unknown teams via a SofaScore team URL.

**Returns:** team profile {name,manager,venue,founded,pregame_form,...}

**Example request body:**
```json
{
  "team_id": "17"
}
```

### POST /sports-data/v1/team_squad — 1 credit
A club's full current squad (every player with id, position, value) by SofaScore team id.

**Parameters:**
- `team_id` (string, required) — SofaScore team id (NOT the ESPN id) — e.g. 17 = Manchester City, 42 = Arsenal. Resolve unknown teams via a SofaScore team URL.

**Returns:** team_id, squad[] (players), count

**Example request body:**
```json
{
  "team_id": "17"
}
```

### POST /sports-data/v1/team_transfers — 1 credit
A club's transfers in and out (player, club, fee, date) by SofaScore team id.

**Parameters:**
- `team_id` (string, required) — SofaScore team id (NOT the ESPN id) — e.g. 17 = Manchester City, 42 = Arsenal. Resolve unknown teams via a SofaScore team URL.

**Returns:** transfers{in[],out[]}, count

**Example request body:**
```json
{
  "team_id": "17"
}
```

### POST /sports-data/v1/team_season_stats — 2 credits
team's season statistics in a league

**Parameters:**
- `team_id` (string, required) — SofaScore team id (NOT the ESPN id) — e.g. 17 = Manchester City, 42 = Arsenal. Resolve unknown teams via a SofaScore team URL.
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `type` (enum, optional, default "overall") — Stat split. Other SofaScore split keys are accepted but a wrong one 404s. [one of: overall, home, away]
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** statistics{} for the team's season

**Example request body:**
```json
{
  "team_id": "17",
  "league": "eng.1",
  "season_id": "61627"
}
```

### POST /sports-data/v1/team_form — 1 credit
team recent form + next/prev event

**Parameters:**
- `team_id` (string, required) — SofaScore team id (NOT the ESPN id) — e.g. 17 = Manchester City, 42 = Arsenal. Resolve unknown teams via a SofaScore team URL.

**Returns:** recent[]{result}, next_event, previous_event

**Example request body:**
```json
{
  "team_id": "13"
}
```

### POST /sports-data/v1/team_goal_distributions — 1 credit
goals scored/conceded by match period

**Parameters:**
- `team_id` (string, required) — SofaScore team id (NOT the ESPN id) — e.g. 17 = Manchester City, 42 = Arsenal. Resolve unknown teams via a SofaScore team URL.
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** distributions[] (goals scored/conceded by match period)

**Example request body:**
```json
{
  "team_id": "13",
  "league": "eng.1"
}
```

### POST /sports-data/v1/season_standings — 2 credits
SofaScore league table for a competition (overall / home / away splits) with goals for/against and goal difference.

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `type` (enum, optional, default "total") — Which standings table to return. [one of: total, home, away]
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** standings[] tables{rows[]} (overall/home/away split, any season), count

**Example request body:**
```json
{
  "league": "eng.1"
}
```

### POST /sports-data/v1/season_top_players — 2 credits
season leaders by category

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `type` (enum, optional, default "overall") — Split for the season leaders. [one of: overall, home, away]
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** top_players{category:[{player,team,value}]}, count

**Example request body:**
```json
{
  "league": "eng.1",
  "season_id": "61627"
}
```

### POST /sports-data/v1/season_top_teams — 2 credits
season top teams by category

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `type` (enum, optional, default "overall") — Split for the season leaders. [one of: overall, home, away]
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** top_teams{category:[{team,value}]}, count

**Example request body:**
```json
{
  "league": "eng.1",
  "season_id": "61627"
}
```

### POST /sports-data/v1/team_of_week — 2 credits
team of the week (round or rounds list)

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `round_id` (string, optional) — Specific round id; omit to list the available rounds.
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** the round's TOTW {formation,players[]} OR the rounds[] list

**Example request body:**
```json
{
  "league": "eng.1"
}
```

### POST /sports-data/v1/power_rankings — 2 credits
season power rankings

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `round_id` (string, optional) — Specific round id; omit to list the available rounds.
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** rankings[]{rank,team,points,change} (or rounds list)

**Example request body:**
```json
{
  "league": "eng.1"
}
```

### POST /sports-data/v1/cup_tree — 2 credits
knockout bracket / cup tree

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.
- `season` (integer, optional) — Season year (soccer standings need it; default current season).
- `season_id` (string, optional) — Explicit SofaScore season id (skips season resolution).

**Returns:** cup_trees[]{rounds[]{blocks[]}}, count

**Example request body:**
```json
{
  "league": "eng.1"
}
```

### POST /sports-data/v1/tournament_details — 1 credit
Competition metadata: country, tier, and the clubs with the most titles — by league key.

**Parameters:**
- `league` (string, required) — League key (e.g. 'eng.1', 'nba'), a raw name to search, or a SofaScore numeric unique-tournament id.

**Returns:** tournament meta {name,country,tier,titles,...}

**Example request body:**
```json
{
  "league": "eng.1"
}
```

### POST /sports-data/v1/manager — 1 credit
Manager profile and full club-by-club career history (matches, wins, points) by SofaScore manager id.

**Parameters:**
- `manager_id` (string, required) — SofaScore manager id (from entity_search).

**Returns:** manager profile + career[] history

**Example request body:**
```json
{
  "manager_id": "794075"
}
```

### POST /sports-data/v1/referee — 1 credit
referee details + per-tournament stats

**Parameters:**
- `referee_id` (string, required) — SofaScore referee id (from entity_search).

**Returns:** referee profile + by_tournament[] stats

**Example request body:**
```json
{
  "referee_id": "65702"
}
```

### POST /sports-data/v1/rankings — 1 credit
World rankings — FIFA men's football, or ATP / WTA tennis (set type; defaults to FIFA).

**Parameters:**
- `type` (enum, optional, default "fifa") — Which world ranking to return. Closed set: fifa, atp, wta (a wrong value returns INVALID_PARAM). [one of: fifa, atp, wta]

**Returns:** type, rankings[]{rank,name,points,previous_rank,country}, count

**Example request body:**
```json
{
  "type": "fifa"
}
```

## More
- Try it live, no code: https://reefapi.com/playground?engine=sports-data
- Human docs page: https://reefapi.com/docs/sports-data
- Every ReefAPI API in one file (for your AI): https://reefapi.com/llms-full.txt
