STAT-API

NBA game_lines API

game_linesnba.game_lines
NBA game betting lines — point spreads, moneylines, and over/under totals from sportsbooks, captured over time as the lines move from opening to closing.
GET/api/v1/nba/game_lines
Requires one of: game_id — requests satisfying none of these return 400.
Parameters
game_idquerybigintoptional
Filter to a single game.
season_idquerybigintoptional
Filter by season.
operator_idquerybigintoptional
Filter by sportsbook id: 6 Consensus (full history), 1 DraftKings, 2 FanDuel, 1683 Pinnacle, 1684 BetMGM, 1685 Caesars, 1686 BetRivers, 1687 ESPN BET (per-book rows begin 2026-05).
is_openingquerybooleanoptional
Filter to opening lines only. Reliable from the 2025-26 season; earlier seasons largely lack opener flags.
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/game_lines?game_id=1'
Responses
200game_lines rows matching the declared filter set, wrapped in { game_lines, 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(30 fields)show schema ▸
FieldTypeReferencesDescription
idkey
bigint—Primary Key
game_id
bigint—
e.g. 16082
operator_id
bigintSportsbook id: 6 Consensus (full history); per-book ids (1 DraftKings, 2 FanDuel, 1683 Pinnacle, 1684 BetMGM, 1685 Caesars, 1686 BetRivers, 1687 ESPN BET) begin 2026-05.
e.g. 6
season_id
bigintDenormalized for efficient season-level queries
e.g. 2021
captured_at
timestamptz—When this snapshot was captured
e.g. 2022-04-10T00:00:00.000Z
implied_away_score
decimalnullable——
e.g. 109.0000
implied_away_win_pct
decimalnullable——
e.g. 0.4082
implied_home_score
decimalnullable—Calculated from spread + total
e.g. 109.7500
implied_home_win_pct
decimalnullable—From moneyline, 0-1
e.g. 0.6296
is_opening
boolean—True if this is the opening line
Values:falsetrue
moneyline_away
integernullable—American odds for away team win
e.g. 145
moneyline_bet_pct_away
integernullable——
e.g. — (all-null in sample)
moneyline_bet_pct_home
integernullable——
e.g. — (all-null in sample)
moneyline_home
integernullable—American odds for home team win
e.g. -170
moneyline_money_pct_away
integernullable——
e.g. — (all-null in sample)
moneyline_money_pct_home
integernullable——
e.g. — (all-null in sample)
over_odds
integernullable—American odds for over
e.g. 0
spread
decimalnullable—Home team spread (e.g., -3.5 means home favored by 3.5)
e.g. -2.5000
spread_away_odds
integernullable—American odds for away spread
e.g. -110
spread_bet_pct_away
integernullable——
e.g. — (all-null in sample)
spread_bet_pct_home
integernullable——
e.g. — (all-null in sample)
spread_home_odds
integernullable—American odds for home spread (e.g., -110)
e.g. -110
spread_money_pct_away
integernullable——
e.g. — (all-null in sample)
spread_money_pct_home
integernullable——
e.g. — (all-null in sample)
total
decimalnullable—Combined score total line (e.g., 224.5)
e.g. 225.5000
total_bet_pct_over
integernullable——
e.g. — (all-null in sample)
total_bet_pct_under
integernullable——
e.g. — (all-null in sample)
total_money_pct_over
integernullable——
e.g. — (all-null in sample)
total_money_pct_under
integernullable——
e.g. — (all-null in sample)
under_odds
integernullable—American odds for under
e.g. 0
GET/api/v1/nba/game_lines/{id}
Parameters
idpathbigintrequired
Primary key (id) of the game_line 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/game_lines/{pk_value}'
Responses
200Single game_line row.application/jsonshow example ▸
404Row not found.
Response Schema(30 fields)show schema ▸
FieldTypeReferencesDescription
idkey
bigint—Primary Key
game_id
bigint—
e.g. 16082
operator_id
bigintSportsbook id: 6 Consensus (full history); per-book ids (1 DraftKings, 2 FanDuel, 1683 Pinnacle, 1684 BetMGM, 1685 Caesars, 1686 BetRivers, 1687 ESPN BET) begin 2026-05.
e.g. 6
season_id
bigintDenormalized for efficient season-level queries
e.g. 2021
captured_at
timestamptz—When this snapshot was captured
e.g. 2022-04-10T00:00:00.000Z
implied_away_score
decimalnullable——
e.g. 109.0000
implied_away_win_pct
decimalnullable——
e.g. 0.4082
implied_home_score
decimalnullable—Calculated from spread + total
e.g. 109.7500
implied_home_win_pct
decimalnullable—From moneyline, 0-1
e.g. 0.6296
is_opening
boolean—True if this is the opening line
Values:falsetrue
moneyline_away
integernullable—American odds for away team win
e.g. 145
moneyline_bet_pct_away
integernullable——
e.g. — (all-null in sample)
moneyline_bet_pct_home
integernullable——
e.g. — (all-null in sample)
moneyline_home
integernullable—American odds for home team win
e.g. -170
moneyline_money_pct_away
integernullable——
e.g. — (all-null in sample)
moneyline_money_pct_home
integernullable——
e.g. — (all-null in sample)
over_odds
integernullable—American odds for over
e.g. 0
spread
decimalnullable—Home team spread (e.g., -3.5 means home favored by 3.5)
e.g. -2.5000
spread_away_odds
integernullable—American odds for away spread
e.g. -110
spread_bet_pct_away
integernullable——
e.g. — (all-null in sample)
spread_bet_pct_home
integernullable——
e.g. — (all-null in sample)
spread_home_odds
integernullable—American odds for home spread (e.g., -110)
e.g. -110
spread_money_pct_away
integernullable——
e.g. — (all-null in sample)
spread_money_pct_home
integernullable——
e.g. — (all-null in sample)
total
decimalnullable—Combined score total line (e.g., 224.5)
e.g. 225.5000
total_bet_pct_over
integernullable——
e.g. — (all-null in sample)
total_bet_pct_under
integernullable——
e.g. — (all-null in sample)
total_money_pct_over
integernullable——
e.g. — (all-null in sample)
total_money_pct_under
integernullable——
e.g. — (all-null in sample)
under_odds
integernullable—American odds for under
e.g. 0