STAT-API

NBA team_game_contexts API

team_game_contextsnba.team_game_contexts
Situational context for each NBA team in each game — how much the game matters (playoff push, tanking, contender mode, In-Season Tournament stakes), what phase of the season it's in, and how far along the schedule the team is.
GET/api/v1/nba/team_game_contexts
Requires one of: game_id — requests satisfying none of these return 400.
Parameters
game_idquerybigintoptional
Filter to a single game.
team_idquerybigintoptional
Filter by team.
season_idquerybigintoptional
Filter by season.
limitqueryintegeroptionaldefault 50
Page size. Defaults to 50; max 5000.
from_idquerybigintoptional
Return rows with id strictly greater than this value; page using the previous response's `next_from_id`. Omit on the first page.
Restores the documented defaults (trial keys only accept the unchanged defaults).
Request
curl -sS --compressed \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  'https://api.stat-api.com/api/v1/nba/team_game_contexts?game_id=1'
Responses
200team_game_contexts rows matching the declared filter set, wrapped in { team_game_contexts, limit, next_from_id }. next_from_id is the last row's id on a full page — pass it back via ?from_id= to walk the full result; null marks the terminal page.application/jsonshow example ▸
400No declared filter set was satisfied — response body matches MissingRequiredFiltersError; pick one combo from the accepted-sets hint and resend.application/json
Response Schema(20 fields)show schema ▸
FieldTypeReferencesDescription
idkey
bigint—Primary Key
game_id
bigint—
e.g. 2374
opponent_team_id
bigint—
e.g. 9
season_id
bigint—
e.g. 2024
team_id
bigint—
e.g. 9
conference_rank
integer——
e.g. 8
game_type
string—regular, playoff, play_in, ist_group, ist_knockout, preseason, allstar
Values:regularplayoffist_group
games_remaining
integer——
e.g. 0
intensity
integer—1-10 motivation intensity scale
e.g. 5
is_back_to_back
boolean——
Values:falsetrue
is_clinch
boolean——
Values:falsetrue
is_elimination
boolean——
Values:falsetrue
ist_group_rank
integernullable——
e.g. — (all-null in sample)
ist_group_record
stringnullable—e.g. 2-1
e.g. — (all-null in sample)
motivation
string—contender, playoff_lock, seeding_battle, playoff_push, play_in, fringe, tanking, eliminated, early_season, playoff_comfortable, playoff_competitive, playoff_desperate, playoff_elimination, playoff_clinch, ist_contending, ist_eliminated, ist_knockout
Values:play_infringeearly_seasonseeding_battlecontendertankingplayoff_lockplayoff_competitiveplayoff_comfortableplayoff_desperateplayoff_clinchplayoff_eliminationist_contending
rest_days
integer——
e.g. 1
season_pct
decimal—0.0-1.0 how far through regular season
e.g. 1.0000
season_phase
string—early, mid, late, final_push, postseason
Values:midlateearlyfinal_pushpostseason
team_series_wins
integer——
e.g. 0
win_pct
decimal——
e.g. 0.5000
GET/api/v1/nba/team_game_contexts/{id}
Parameters
idpathbigintrequired
Primary key (id) of the team_game_context row.
Restores the documented defaults (trial keys only accept the unchanged defaults).
Request
curl -sS --compressed \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  'https://api.stat-api.com/api/v1/nba/team_game_contexts/{pk_value}'
Responses
200Single team_game_context row.application/jsonshow example ▸
404Row not found.
Response Schema(20 fields)show schema ▸
FieldTypeReferencesDescription
idkey
bigint—Primary Key
game_id
bigint—
e.g. 2374
opponent_team_id
bigint—
e.g. 9
season_id
bigint—
e.g. 2024
team_id
bigint—
e.g. 9
conference_rank
integer——
e.g. 8
game_type
string—regular, playoff, play_in, ist_group, ist_knockout, preseason, allstar
Values:regularplayoffist_group
games_remaining
integer——
e.g. 0
intensity
integer—1-10 motivation intensity scale
e.g. 5
is_back_to_back
boolean——
Values:falsetrue
is_clinch
boolean——
Values:falsetrue
is_elimination
boolean——
Values:falsetrue
ist_group_rank
integernullable——
e.g. — (all-null in sample)
ist_group_record
stringnullable—e.g. 2-1
e.g. — (all-null in sample)
motivation
string—contender, playoff_lock, seeding_battle, playoff_push, play_in, fringe, tanking, eliminated, early_season, playoff_comfortable, playoff_competitive, playoff_desperate, playoff_elimination, playoff_clinch, ist_contending, ist_eliminated, ist_knockout
Values:play_infringeearly_seasonseeding_battlecontendertankingplayoff_lockplayoff_competitiveplayoff_comfortableplayoff_desperateplayoff_clinchplayoff_eliminationist_contending
rest_days
integer——
e.g. 1
season_pct
decimal—0.0-1.0 how far through regular season
e.g. 1.0000
season_phase
string—early, mid, late, final_push, postseason
Values:midlateearlyfinal_pushpostseason
team_series_wins
integer——
e.g. 0
win_pct
decimal——
e.g. 0.5000