NBA APINBA player props by sportsbook, with the result.
Closing prop lines by sportsbook since May 2023 for points, rebounds, assists, threes, blocks and steals, each with the player's record against his line. Underneath them, NBA play-by-play since 2003-04 with every shot located, box scores and game odds, plus the WNBA and college basketball. Call it over REST or MCP.
500 free credits every month, no card. Works in Claude, ChatGPT and Cursor: connect over MCP
- plays
- 14.6M+
- games
- 32,000+
- players
- 3,900+
- seasons
- 24
Underneath them, NBA play-by-play since 2003-04 with every shot located, box scores and game odds, plus the WNBA and college basketball. Call it over REST or MCP.
Try it
One request, JSON back.
Copy the call, put your key in, run it. get_player_props costs 10 credits, and every account starts with 500 free credits every month, no card.
Request
curl -X POST https://mcp.dunkapi.com/v1/get_player_props \
-H "Content-Type: application/json" \
-H "x-api-key: YOUR_API_KEY" \
-d '{
"game_id": "401909918",
"market": "player_points",
"bookmaker": "draftkings"
}'Response
{
"snapshot_type": "closing",
"games": 1,
"props": [
{
"game_id": "401909918",
"game_date": "2026-11-02",
"player_name": "Aaron Gordon",
"player_id": "3064290",
"market": "player_points",
"bookmaker": "draftkings",
"line": 13.5,
"over_odds": -113,
"under_odds": -113,
"captured_at": "2026-11-03T01:05:39.626Z",
"scheduled_start": "2026-11-03T02:00:00.000Z",
"minutes_before_scheduled_start": 54.3,
"source": "archive"
},
{
"game_id": "401909918",
"game_date": "2026-11-02",
...First 22 lines. Full response and every field
Also in DunkAPI
The WNBA API
Women's National Basketball Association, every season since 2006: play-by-play, shot locations, standings, sportsbook lines and season lines. Same key and credits as the NBA.
WNBA API: see the data- games
- 4,995
- plays
- 1,936,436
- seasons
- 21
Also in DunkAPI
The college basketball API
NCAA Division I men's basketball, every season since 2013-14: play-by-play, standings, sportsbook lines and season lines. Same key and credits as the NBA.
NCAAM API: see the data- games
- 78,121
- plays
- 25,310,159
- seasons
- 14
Also in DunkAPI
The women's college basketball API
NCAA Division I women's basketball, every season since 2014-15: play-by-play, standings, sportsbook lines and season lines. Same key and credits as the NBA.
NCAAW API: see the data- games
- 67,805
- plays
- 16,685,751
- seasons
- 13
Also in DunkAPI
The NBL API
National Basketball League (Australia and New Zealand), every season since 2023: play-by-play, shot locations, standings, sportsbook lines and season lines. Same key and credits as the NBA.
NBL API: see the data- games
- 722
- plays
- 246,578
- seasons
- 5
This week
What get_schedule returns right now.
Rendered from the same rows get_schedule returns, refreshed every hour. Lines are the median closing number across sportsbooks.
| Tip-off | Away | Home | Line | Total | Game id |
|---|---|---|---|---|---|
| Sun 3:30 PM ET | DET | ATL | DET -1.75 | 224 | 401910029 |
| Sun 6:00 PM ET | OKC | MIA | MIA -3.5 | 231.5 | 401910030 |
| Sun 7:00 PM ET | ORL | WSH | ORL -4.75 | 219.5 | 401910031 |
| Sun 7:00 PM ET | DEN | CHI | DEN -8.75 | 237.5 | 401910032 |
| Sun 7:00 PM ET | DAL | UTAH | DAL -1.25 | 225.5 | 401910033 |
| Sun 8:00 PM ET | IND | NY | NY -8.5 | 213.5 | 401910034 |
get_schedule · 2 credits · then get_game for the box scores and every book's line
Prop history
Every line a player has had, and how they did against it.
- Derrick WhiteBOS
- Josh HartNY
- Jalen BrunsonNY
- Mikal BridgesNY
- Rudy GobertMIN
- Naz ReidCHA
- Nickeil Alexander-WalkerATL
- Karl-Anthony TownsNY
- Myles TurnerMIL
- Payton PritchardBOS
- Shai Gilgeous-AlexanderOKC
- Jaden McDanielsMIN
- Jamal MurrayDEN
- Luguentz DortATL
- Nikola JokicDEN
- Pascal SiakamIND
- Jaylen BrownPHI
- Bam AdebayoMIA
- James HardenCLE
- Anthony EdwardsMIN
- Jarrett AllenCLE
- Michael Porter Jr.BKN
- Donovan MitchellCLE
- Duncan RobinsonDET
Coverage
Coverage you can inspect before you build.
Play-by-play for NBA games since 2003-04, with the location of every shot in it.
Each sportsbook's moneyline, spread and total: 4 to 12 books per regular-season NBA game from 2013-14 to 2023-24 (10 to 12 from 2020-21), opening and closing lines from 6 to 8 books per game since July 2020, 4 to 10 for most men's college seasons, and a median of 4 for women's college games since November 2024.
The WNBA since 2006 and Division I men's (from 2013-14) and women's (from 2014-15) college basketball, on the same tools.
| Dataset | Seasons | Volume | Status | Tools |
|---|---|---|---|---|
Games and box scores Scores, both teams' box scores and every player's line: minutes, points, shooting, rebounds, assists, steals, blocks, turnovers, fouls, plus-minus. | 2003-04 to current | Every game, every player | Partial About one game in eight from 2012-13 to 2017-18 has no box score in the source; those lines are counted from the play-by-play (97-100% exact where checked), without minutes or plus-minus. 26 games have a box score but no play-by-play. | |
Play-by-play Every play with clock, score, players involved, shot type and points. | 2003-04 to current | About 450 plays per NBA game | Full | |
Shot locations Each shot's x/y in feet, distance, zone and our expected points. | 2003-04 to current | Every field goal attempt | Full | |
Win probability The home team's win probability after each play, as computed upstream, not by us. | 2018 to current | After every play | Partial From 2017-18 only. | |
Odds Moneyline, spread and total by sportsbook; opening and closing lines from July 2020 (sportsbook odds archive), the final pregame line only in the earlier seasons. | 2013-14 to current | 4 to 12 books per regular-season game to 2023-24; 6 to 8 with opening and closing lines since July 2020 | Partial No lines before 2012-13; opening and closing lines from July 2020; player props are separate (get_player_props, from May 2023). | |
Ratings Our Elo, before and after every game. | 2003-04 to current | Every team, every game | Full | |
Injury report Each listed player's status, injury and expected return, captured daily (NBA and WNBA). | From launch | Daily | Partial Daily captures from launch; no history before that. |
Full detail in the data atlas. Sportsbooks: the books reported with each game: 4 to 12 per regular-season NBA game from 2013-14 to 2023-24, 10 to 12 from 2020-21 (DraftKings, Caesars, BetMGM, Unibet and Betfair among them in 2023-24), plus up to eight books with opening and closing lines since July 2020, among them DraftKings, FanDuel, BetMGM, ESPN BET and Pinnacle. No lines before 2012-13, and the daily feed is one or two books a game since 2024-25; the other books come from the sportsbook odds archive.
Last written 2026-11-22 15:05 UTC. Every dataset's own refresh time is in the changelog.
Why trust it
The parts of basketball data that take real work.
Box scores are everywhere. Shot locations joined to a value model, a decade of lines by book, and four leagues on one schema are where shortcuts show.
Located, zoned and valued
Every NBA field goal attempt since 2003-04 carries its spot on the floor in feet, its zone and our expected points for that type of shot from that distance, fitted on the league's own history. A shot chart is one call, not a scraping project.
A decade of lines, by sportsbook
Moneylines, spreads and totals from 4 to 12 sportsbooks per NBA game from 2013-14 to 2023-24 (10 to 12 from 2020-21), opening and closing lines from 6 to 8 books since July 2020, and most college seasons, each stored separately, with results against the median close. Enough history to backtest a model across eras, not just last season.
The same tools, one argument apart
The NBA, the WNBA and men's and women's Division I college basketball share one set of endpoints. Pass league and the same box scores, play-by-play, standings and ratings come back for that league, each kept in its own tables.
Tools
Every tool, and what a call costs.
Every tool is one REST endpoint and one MCP tool with the same name, the same parameters, and a fixed credit cost. Empty results are not charged.
- list_gamesGames with scores by season, date, range or team
- get_scheduleUpcoming games with the median line across sportsbooks
- get_standingsStandings from every final game: overall, conference, home, away, last 10
- get_injuriesThe latest injury report: status, injury and expected return (NBA, WNBA)
- get_ratingsOur team Elo ratings, ranked
- get_gameOne game: both box scores, every player's line, each book's line, win probability
- get_playerProfile, per-season averages and shooting splits, last 10 games
- get_player_gamesA player's full game log
- get_leadersSeason leaders per game, by percentage or in total
- get_team_statsPace, offensive, defensive and net rating, and the four factors
- get_oddsEvery sportsbook's moneyline, spread and total for a game (5) or a day (10), with results against the line
- get_game_probabilitiesWhat the market thinks of a game: average implied and fair probability for the moneyline, spreads and totals
- get_playsPlay-by-play with shot locations, zones, expected points and win probability
- get_shot_chartShot profile by zone for a player, team or defence, with every shot's x/y
- get_player_propsPlayer prop lines by sportsbook: the closing line (one pre-game capture per line before October 2026)
- get_prop_historyA player's prop lines against the result, game by game
- get_prop_probabilitiesWhat the market thinks of a game's player props: average implied and fair probability for each player and line
- get_alt_linesAlternate spreads and totals by sportsbook: every point on each book's ladder, opening and closing, NBA, WNBA and men's college from 2023-24
- get_line_movementSnapshots of each sportsbook's line before tip-off
- get_prop_movementHow one player's prop line moved before a game, every capture by sportsbook
- get_market_oddsOpening and closing lines by sportsbook for the half and quarter markets (from May 2023, each game added the morning after it is played)
Built for
Four jobs, and the endpoints that do them.
Every NBA shot since 2003-04, with where it was taken
Play-by-play with x/y for every field goal attempt, expected points per shot and shot zones, joined to box scores.
Read more →A decade of sportsbook lines next to the games
Moneyline, spread and total from 4 to 12 books per regular-season game for 2013-14 to 2023-24, with opening and closing lines from 6 to 8 books since July 2020, joined to the result and our ratings.
Read more →Basketball data your app or agent can query
REST and MCP over the NBA, WNBA and college basketball: games, players, plays, odds and ratings, with stable ids.
Read more →Guides
Working code for the questions people ask.
- get_plays
How do I get NBA play-by-play data in Python?
One call returns a game's plays in order, with shot location, zone, expected points and win probability on each. This pulls the shots from one game into pandas.
Python, JavaScript, cURL → - get_shot_chart
How do I build an NBA shot chart by zone in Python?
A player's shot profile by zone, with attempts, makes and expected points per shot, for one season. Set include_shots to true to get every shot's x and y as well.
Python, JavaScript, cURL → - get_odds
How do I backtest NBA closing lines in Python?
A day of games with every sportsbook's opening and closing moneyline, spread and total, next to whether the home side covered and the total went over.
Python, JavaScript, cURL →
Integrations
In your AI assistant, your editor or your spreadsheet.
All integrationsAccess
REST or MCP. Same data either way.
Call it from any language over REST. Let Claude or Cursor query it in plain English over MCP.
- GET https://mcp.dunkapi.com/v1/tools public catalogue with JSON Schema
- GET https://mcp.dunkapi.com/openapi.json OpenAPI 3.1 spec
- POST https://mcp.dunkapi.com/v1/{tool}
- MCP https://mcp.dunkapi.com/mcp
curl -X POST https://mcp.dunkapi.com/v1/list_teams \
-H "x-api-key: YOUR_API_KEY"
# every tool: POST /v1/{tool} with a JSON body
# responses carry X-Credits-Used and X-Credits-RemainingPricing
Free to start, then you pay per call.
500 credits every month, no card. Subscriptions add a monthly allowance; wallet top-ups do not expire while your account is open.
- +All 24 endpoints
- +REST API + MCP access
- +No credit card required
- +10,000 credits/month
- +All 24 endpoints
- +Email support
- +Overage at wallet rates
- +30,000 credits/month
- +All 24 endpoints
- +Priority support
- +Overage at wallet rates
- +125,000 credits/month
- +All 24 endpoints
- +Dedicated support
- +Volume rates available
Full breakdown, credit costs per tool, and FAQ on the pricing page.
Questions
The things people ask before signing up.
Is DunkAPI free?
Every account gets 500 credits every month and no card. Calls cost 1 to 25 credits depending on the endpoint, so 500 is a few hundred real requests. Paid plans start at $19/mo for 10,000 credits a month, and wallet top-ups do not expire while your account is open.
How far back does the data go?
NBA play-by-play, with the location of every shot, runs from the 2003-04 season to today; win probability starts in 2017-18. Sportsbook lines start in 2012-13 and carry 4 to 12 books per regular-season game from 2013-14 to 2023-24 (10 to 12 from 2020-21), then usually one in the daily feed; since July 2020 the sportsbook odds archive adds opening and closing lines from 6 to 8 books per game. The WNBA runs from 2006, men's college from 2013-14 and women's college from 2014-15, with about ten books per men's college game to 2023-24.
What is MCP, and do I need it?
MCP is the protocol Claude, Cursor and similar assistants use to call tools. Point one at https://mcp.dunkapi.com/mcp with your key and it picks the endpoint and reads the response itself, no client code. If you are writing an application instead, ignore MCP and use the REST endpoints; they are the same 24 tools.
Can I use this commercially?
Yes, inside your own product or model, within the terms. Reselling the data itself as a feed is not permitted. DunkAPI is independent and not affiliated with the NBA, the WNBA or the NCAA.
How current is it?
Odds refresh every hour for games in the next four days. Everything else updates once a day, early morning US Eastern (10:00 UTC): scores, box scores and the previous night's play-by-play, the next week's schedule, the day's lines, the injury report and the ratings. There is no live in-game feed.
Where do the stats come from?
Games, box scores, play-by-play, shot locations, win probability and injuries from public data; sportsbook lines are captured from the books that post them. Shot zones, expected points per shot, pace, offensive and defensive ratings, standings and team Elo are computed here from those rows. Nothing is licensed from another analytics provider.
What are the rate limits?
60 requests a minute, dropping to 10 if your credit balance falls below 100. The limit is the same on every plan: credits, not requests, are the spend boundary.
Before you write another scraper
Start with 500 free credits every month, no card.
DunkAPI · The basketball data API.