The NBA API for stats, tracking and player props
From box scores to the stats behind them: tracking and hustle numbers, play types, shot zones, pull-up and catch-and-shoot splits, drives, potential assists, on/off usage swings, defense vs position, and per-book player prop odds with hit rates.
Free tier, no credit card. 21 NBA endpoints. One stable /v1 contract with an OpenAPI 3.1 spec.
# Pro plan. Send your key in the x-api-key header.
curl "https://api.statyx.io/v1/nba/players/1000115/hit-rates?market=pra&line=42.5&windows=L5,L10,L20,season" \
-H "x-api-key: sk_live_••••••••"
{
"data": {
"player_id": 1000115,
"market": "pra",
"line": 42.5,
"side": "over",
"season": null,
"sample_size": 40,
"windows": {
"L5": {
"games": 5,
"hits": 4,
"hit_rate": 0.8,
"pct": 80,
"average": 45.2
},
"L10": {
"games": 10,
"hits": 7,
"hit_rate": 0.7,
"pct": 70,
"average": 44.1
},
"L20": {
"games": 20,
"hits": 13,
"hit_rate": 0.65,
"pct": 65,
"average": 43.1
},
"season": {
"games": 40,
"hits": 25,
"hit_rate": 0.625,
"pct": 63,
"average": 42.8
}
}
},
"meta": {
"player_id": 1000115,
"market": "pra",
"line": 42.5
}
}
What's in the NBA API
Raw feeds and the analytics computed from them, under one set of ids.
- Schedule, players and standings
- Game box scores
- Tracking and hustle: usage, PIE, off/def rating, touches
- Deflections, contested shots, charges and box outs
- Play types: isolation, pick & roll, spot-up, transition, post-up
- Play-type defense: points allowed per play type
- Shot zones and zone defense (FG% by court area)
- Shooting splits: pull-up and catch-and-shoot
- Drives and scoring breakdown
- Potential assists and assist profiles
- Usage shock: how a teammate being out moves usage
- Defense vs position (PG / SG / SF / PF / C)
- Hit rates and combos (PRA, P+R, P+A)
- Player prop odds by book, and matchup history
21 endpoints, and the plan each needs
Every endpoint below is live today. Full parameters, field definitions and sample responses are in the docs.
| Endpoint | What it returns | Plan |
|---|---|---|
GET /v1/nba/contracts | Current-season player contracts: cap hit, base salary, total cash and salary rank. | Free |
GET /v1/nba/players | Player directory with draft info. | Free |
GET /v1/nba/schedule | Games with scores and status. | Free |
GET /v1/nba/standings | Conference/division records and ranks. | Free |
GET /v1/nba/defense-vs-position | Per-position stats each defense allows per game over its last 15 or 30 games (window=l15 or l30, default l30), rebuilt after every box-score sync:… | Pro |
GET /v1/nba/play-type-defense | Per-team points allowed per play type: possessions, PPP, points, FG% / eFG% and percentile rank. | Pro |
GET /v1/nba/players/{playerId}/advanced-stats | Tracking, hustle & advanced, one row per game: TS%, usage, PIE, ratings, touches, contested shots, deflections, box-outs. | Pro |
GET /v1/nba/players/{playerId}/assist-profile | Playmaking profile for the current season, recomputed twice a day: averages over the player's last 10 and last 20 games played (assists, potential… | Pro |
GET /v1/nba/players/{playerId}/drives | Drive volume and efficiency per season (per-game averages, regular season): drives per game, points, assists, FG%, turnovers and league percentile… | Pro |
GET /v1/nba/players/{playerId}/game-stats | Per-game box score with shooting splits and plus/minus. | Pro |
GET /v1/nba/players/{playerId}/hit-rates | Hit rate for points, rebounds, assists, threes, PRA and other combos. | Pro |
GET /v1/nba/players/{playerId}/matchup-history | Per-game history against opponents: the stat line, combo totals (PRA, P+R, P+A, R+A, Stl+Blk), each market's closing line (the last line posted… | Pro |
GET /v1/nba/players/{playerId}/odds | Player prop odds per market and sportsbook: line, over/under prices, the offering book, and every book quoting the market (all_sportsbooks JSONB). | Pro |
GET /v1/nba/players/{playerId}/play-types | Offensive play-type breakdown from the league's play-type tracking, per season and season type (2024-25 on): for spot up, iso, P&R ball-handler /… | Pro |
GET /v1/nba/players/{playerId}/potential-assists | Per-game potential assists (passes that would be assists if the shot were made), with minutes, matchup and result, 2024-25 on. | Pro |
GET /v1/nba/players/{playerId}/scoring-breakdown | Shot diet and assisted / unassisted split: percent of points from fastbreak, paint, off turnovers, 2PT vs 3PT, and share of makes that were… | Pro |
GET /v1/nba/players/{playerId}/shooting-splits | Pull-up and catch-and-shoot shooting splits per season (per-game averages, regular season): makes, attempts, FG%, 3PT, points and eFG% for each shot… | Pro |
GET /v1/nba/players/{playerId}/shot-zones | FG% by court zone: restricted area, paint (non-RA), mid-range, left/right corner 3 and above-the-break 3. | Pro |
GET /v1/nba/shot-zone-defense | Per-team opponent FG% allowed by court zone (restricted area, paint, mid-range, corner 3s, above-break 3). | Pro |
GET /v1/nba/team-assist-defense | Team defensive and assist profile: what the defense allows (assists, points, paint, fastbreak, off turnovers) plus pace, paint touches and the… | Pro |
GET /v1/nba/usage-shock | On/off usage swing: how a lineup redistributes when one player leaves the floor. | Pro |
Start free, upgrade when you ship
No contracts and no setup fees. Change plans any time; access follows your key immediately.
Teams, players, schedules and standings. 4 NBA endpoints. 30 requests a minute. No credit card.
Start freeEverything in Free plus full box scores, advanced stats, hit rates and the live odds board. 600 requests a minute.
Get ProEvery sport and every engine: projections, game simulations, the HR model and more. 800 requests a minute.
Get All-AccessFrequently asked questions
Is there a free NBA API?
Yes. The Free plan includes 4 NBA endpoints, such as /v1/nba/contracts, /v1/nba/players, /v1/nba/schedule, /v1/nba/standings, at 30 requests a minute. No credit card is needed to start.
How much does the NBA API cost?
Pro is $24.99 a month per sport and adds full stats, box scores, hit rates and the live odds board. All-Access is $89.99 a month for every sport and every engine, including projections and game simulations. Plans are month to month with no setup fee.
Can I use the data in a commercial app?
Yes. Paid plans cover showing the data in your own app or site, free or paid, including to your users at scale. Reselling or redistributing the raw data as a feed or dataset is not included; contact us for that.
What format is the data in, and how do I authenticate?
JSON over HTTPS in one consistent { data, meta } envelope. Send your key in the x-api-key header. A public OpenAPI 3.1 spec at /v1/openapi.json lets you generate a client in any language.
Do players, teams and games keep the same ids across endpoints?
Yes. Every endpoint uses the same stable Statyx ids, so a player or game from one endpoint joins directly to stats, odds and props from another.
More from the Statyx API
Make your first call in two minutes
Create a free key, paste the curl above, and you have live NBA data in JSON.