Developers

NBA Data REST API

Read-only access to teams, players, game logs, transactions, schedules, scores, games, injuries, and box scores.

OpenAPI specification

Use the machine-readable version 1 OpenAPI 3.0 JSON document to generate clients, import the API into development tools, or explore its request and response schemas. The unversioned /openapi.json URL remains available as a compatibility alias for the current version.

Authentication

API data is provided for personal, non-commercial entertainment only and is not financial or betting advice. Use is subject to the Terms and Conditions.

Create one API token from your profile. Send it in the HTTP Authorization header. Tokens are shown once and cannot be recovered; rotate or delete a token from your profile if it is exposed.

New tokens begin with nbastat_. Existing tokens that begin with nba_live_ remain valid.

curl "https://nbastat.io/api/v1/teams" \
  -H "Authorization: Bearer YOUR_API_TOKEN"

Tokens do not expire automatically. Never place a token in a URL, browser source code, repository, log, or public message.

Rate limits

The default limit is 10 authenticated requests in any rolling 60-minute window. The limit will be increased in the future depending on server capacity. Rotating a token does not reset the account limit.

Responses include RateLimit-Limit, RateLimit-Remaining, and RateLimit-Reset. A limited response uses HTTP 429 and includes Retry-After.

Endpoints

All id values, detail route parameters, team_id filters, and relationship fields are NBA Stat internal IDs. They are stable API identifiers but are not NBA feed identifiers. Scraped NBA identifiers are not exposed as entity IDs.

GET /api/v1/teams

Return all 30 NBA teams, ordered by full team name. This endpoint has no query parameters or pagination.

Each team includes id, name, full_name, alias, and conference (East or West).

GET /api/v1/teams/{team_id}

Retrieve one NBA team by its numeric NBA Stat internal ID. The response has the same fields as a team in the list, including conference.

team_id required path integer
The internal id returned by a team list or relationship field.

GET /api/v1/teams/{team_id}/game-log

List completed game statistics for one team. Each row includes the opponent, result, location, preseason flag, and team box-score totals.

team_id required path integer
The internal id of the team.
season optional string
Limit results to a season in YYYY-YY format, such as 2025-26.
date_from optional date
Include games on or after this date, formatted YYYY-MM-DD.
date_to optional date
Include games on or before this date, formatted YYYY-MM-DD. It cannot be earlier than date_from.
order optional enum
Scheduled-time sort direction: asc or desc; defaults to desc.
page optional integer
Results page to return. Must be 1 or greater; defaults to 1.
per_page optional integer
Records per page, from 1 to 100; defaults to 25.

Example: /api/v1/teams/12/game-log?season=2025-26&order=desc

GET /api/v1/players

List players, with optional name and team filters. Player records include date_of_birth as a YYYY-MM-DD string when known.

q optional string
Search part of a player’s name, display name, first name, or last name. Maximum 100 characters.
team_id optional integer
Return players currently assigned to this NBA Stat internal team ID.
page optional integer
Results page to return. Must be 1 or greater; defaults to 1.
per_page optional integer
Records per page, from 1 to 100; defaults to 25.

Example: /api/v1/players?q=James&team_id=12&page=1

GET /api/v1/players/{player_id}

Retrieve one player by numeric NBA Stat internal ID.

player_id required path integer
The internal id returned by a player list or relationship field.

GET /api/v1/players/{player_id}/game-log

List completed game-by-game statistics for one player, including starts, minutes, shooting, rebounds, assists, defensive statistics, plus/minus, and recorded DNP details.

player_id required path integer
The internal id of the player.
season optional string
Limit results to a season in YYYY-YY format, such as 2025-26.
date_from optional date
Include games on or after this date, formatted YYYY-MM-DD.
date_to optional date
Include games on or before this date, formatted YYYY-MM-DD. It cannot be earlier than date_from.
order optional enum
Scheduled-time sort direction: asc or desc; defaults to desc.
page optional integer
Results page to return. Must be 1 or greater; defaults to 1.
per_page optional integer
Records per page, from 1 to 100; defaults to 25.

Example: /api/v1/players/1/game-log?season=2025-26&per_page=20

GET /api/v1/player-movements

List player trades, signings, waivers, and other recorded roster transactions. Results are newest first by default.

player_id optional integer
Return transactions for this NBA Stat internal player ID.
team_id optional integer
Return transactions associated with this NBA Stat internal team ID.
transaction_type optional string
Match an exact recorded transaction type, such as Trade, Signing, or Waive. Maximum 30 characters.
date_from optional date
Include transactions on or after this date, formatted YYYY-MM-DD.
date_to optional date
Include transactions on or before this date, formatted YYYY-MM-DD. It cannot be earlier than date_from.
order optional enum
Transaction-date sort direction: asc or desc; defaults to desc.
page optional integer
Results page to return. Must be 1 or greater; defaults to 1.
per_page optional integer
Records per page, from 1 to 100; defaults to 25.

Example: /api/v1/player-movements?team_id=12&date_from=2026-07-01&order=desc

GET /api/v1/player-movements/{movement_id}

Retrieve one player movement by its numeric NBA Stat internal movement ID.

movement_id required path integer
The internal id returned by the player-movement collection.

GET /api/v1/injuries

List current or historical game-specific injury snapshots. Availability and play probability are estimates, not official designations or betting advice.

team_id optional integer
Return snapshots for this NBA Stat internal team ID.
player_id optional integer
Return snapshots for this NBA Stat internal player ID.
availability optional enum
One of Available, Probable, Questionable, Doubtful, Out, or Unknown.
scope optional enum
upcoming returns future scheduled games and is the default. all also includes historical snapshots.
page optional integer
Results page to return. Must be 1 or greater; defaults to 1.
per_page optional integer
Records per page, from 1 to 100; defaults to 25.

Example: /api/v1/injuries?team_id=5&availability=Questionable

GET /api/v1/games

List schedules and scores, ordered by scheduled tip-off time.

date_from optional date
Include games on or after this game date, formatted YYYY-MM-DD.
date_to optional date
Include games on or before this game date, formatted YYYY-MM-DD. It cannot be earlier than date_from.
team_id optional integer
Return games where this internal team ID is either the home or away team.
status optional enum
One of Final, In Progress, Not Started, Scheduled, or Postponed. Values are case-sensitive.
season optional string
Season label in YYYY-YY format, such as 2026-27.
order optional enum
Tip-off sort direction: asc or desc; defaults to asc.
page optional integer
Results page to return. Must be 1 or greater; defaults to 1.
per_page optional integer
Records per page, from 1 to 100; defaults to 25.

Example: /api/v1/games?date_from=2026-10-10&date_to=2026-10-17&status=Scheduled&order=asc

GET /api/v1/games/{game_id}

Retrieve one scheduled or completed game by its numeric NBA Stat internal ID.

game_id required path integer
The internal id returned by a game list or relationship field.

GET /api/v1/games/{game_id}/boxscore

Retrieve game details and player box-score statistics using the game’s internal ID. Scheduled games may return an empty players array.

game_id required path integer
The internal id of the game whose player box score should be returned.

GET /api/v1/games/{game_id}/lineup

Retrieve game details and the five projected or confirmed starters for each team. The lineup array can be empty if projections have not been generated.

game_id required path integer
The internal id of the game whose lineup should be returned.

GET /api/v1/games/{game_id}/injuries

Retrieve the injury and estimated availability snapshots saved for one game. Completed-game snapshots are retained for historical reference.

game_id required path integer
The internal id of the game whose injury snapshots should be returned.

GET /api/v1/draftkings/slates

List DraftKings NBA Classic salary slates. A slate is one DraftKings draftGroupId — one coherent player pool with one shared lock time; a single calendar day can have several (Early, Main, Turbo, Night). Unofficial; not affiliated with DraftKings.

date_from optional date
Include slates on or after this slate date, formatted YYYY-MM-DD.
date_to optional date
Include slates on or before this slate date, formatted YYYY-MM-DD. Cannot be earlier than date_from.
order optional enum
Slate start-time sort direction: asc or desc. Defaults to asc.
page optional integer
Results page to return. Defaults to 1.
per_page optional integer
Records per page, from 1 to 100. Defaults to 25.

Example: /api/v1/draftkings/slates?date_from=2026-11-07&order=asc

GET /api/v1/draftkings/slates/{draftgroup_id}

Retrieve one DraftKings slate by its draftGroupId, with its player and game counts.

draftgroup_id required path integer
DraftKings' own technical ID for the slate, as returned by the slate list.

GET /api/v1/draftkings/slates/{draftgroup_id}/salaries

Retrieve a DraftKings slate's full salary player pool. Each row includes DraftKings' own salary, roster-slot eligibility, and status, plus the matching NBA Stat internal player_id and team_id when the DraftKings player has been matched to a known player. This endpoint is not paginated — it always returns the slate's complete player pool in one call, the same as a game's box score or lineup.

draftgroup_id required path integer
DraftKings' own technical ID for the slate whose salaries should be returned.

Pagination and responses

The player, team game-log, player game-log, player-movement, injury, and game collection endpoints default to 25 records. Set per_page from 1 to 100 and use page to move through results. The teams endpoint always returns all 30 teams and does not include pagination metadata.

{
  "data": [],
  "meta": {
    "page": 1,
    "per_page": 25,
    "total": 30,
    "total_pages": 2
  },
  "request_id": "00000000-0000-4000-8000-000000000000"
}

Errors

Errors use standard HTTP status codes: 401 for authentication, 404 for missing resources, 405 for unsupported methods, 422 for invalid parameters, and 429 for rate limits.

{
  "error": {
    "code": "invalid_parameter",
    "message": "date_from must use the YYYY-MM-DD format."
  },
  "request_id": "00000000-0000-4000-8000-000000000000"
}