Tutorial · 9 min · endpoints verified 2026-09-22
How to build an NBA props tracker
Fetch a player line, show the rolling hit-rate context, and make stale or missing prices impossible to mistake for a current market.
API coverage and endpoint overview: Explore the NBA API
Why this is hard
A returned line is not automatically a current line
The useful product is not a number in a card. It is a line tied to a player, market, timestamp and sample window, with a visible state when any of those pieces is absent or old.
- Off-season and settled prices can remain queryable, so freshness must render beside the line.
- A rolling hit rate needs its sample window; the percentage alone is incomplete.
- Player ids must come from a served discovery path rather than a name guess.
- A missing market is an empty state, not a synthetic 0.5 line.
Path 1 · recommended
Have your AI agent build it
Use MCP to inspect basketball coverage and find the player context. The player-props route itself is REST-only, so have the agent call it over HTTP with the same account.
1. Connect the MCP server
Add the server in your MCP client and sign in with your Big Balls account. Your client registers itself and handles the token exchange — there is no key to copy.
{
"mcpServers": {
"bigballs-sports-data": {
"url": "https://mcp.bigballsdata.com/mcp"
}
}
}2. Tools your agent gets
find_playersFind canonical player IDs by name for use with player-stat tools.
get_player_statsPer-player career or per-season totals and per-game rates.
get_coverageMachine-readable map of what we hold and what we do not.
3. Ask for what you want
Paste this at your agent. It is written to make the model check coverage before it designs anything, which is what stops it inventing a field we do not serve.
Build an NBA player-props tracker. Check basketball coverage first,
resolve a canonical player id, then call the NBA props REST endpoint. Render the
line, market, rolling sample and freshness together. If the response is stale or
has no line, show that state and do not substitute a plausible value.What the agent cannot reach
The MCP server does not expose the NBA props route. It can establish coverage and identity, but the line and freshness block must come from REST.
Path 2 · hand-coded
Build it yourself
The tracker follows a served player id into the props response and treats freshness as data, not footer copy.
- 01
Resolve the player before the market
Use a served NBA player list or leader row and retain the identifier required by the props route. Do not resolve a player by display name inside the card.
Start from a served leaderboardbashcurl -s "https://api.bigballsdata.com/v1/nba/leaders?stat=pts&limit=25" \ -H "Authorization: Bearer $BBS_API_KEY" - 02
Fetch one documented prop market
Request the player route and keep market, line, prices, sample window and freshness from the same response.
Fetch the player props responsebashcurl -s "https://api.bigballsdata.com/v1/nba/players/$PLAYER_ID/props" \ -H "Authorization: Bearer $BBS_API_KEY" - 03
Gate the current-price presentation
Only style a line as current when its freshness status supports that claim. Keep stale, recent and missing states visible and preserve the response timestamp.
Model freshness explicitlytypescriptconst state = response.data?.line == null ? 'missing' : response.freshness?.status ?? 'unknown'; return { state, dataAsOf: response.freshness?.data_as_of ?? null, line: response.data?.line ?? null };
Reference
Every endpoint this tutorial uses
All on the gateway at api.bigballsdata.com. Verified against production on 2026-09-22.
| Method | Path | Returns | Why you need it | Plan |
|---|---|---|---|---|
| GET | /v1/nba/leaders | Qualified NBA leaders with player identity and team context | A served identity source for the player selector. | Free |
| GET | /v1/nba/players/:id/props | Held player lines, rolling hit-rate context and freshness metadata | The tracker card and the source of its freshness state. Read the freshness guide. | Free |
Pricing, honestly
Player props start free; game markets are separate
The player props route has a Free entry point. Current full-game odds are an Edge capability and must not be implied by access to a player line.
Free player context
GET /v1/nba/players/:id/propsEdge game markets
GET /v1/matches/:id/odds- Freshness metadata is part of the Free response contract.
- An upgrade does not make an old line current.
- Game markets and player props are different product surfaces.
- Missing markets remain honest empty states on every plan.
More tutorials
Other build guides
- How to build a fantasy hockey app
- How to build a fantasy basketball app
- How to build an NBA scoreboard
- How to build an NHL scoreboard
- How to build an NBA shot chart
- How to build an NBA matchup page
- How to build an NHL props tracker
- How to build an NHL xG explorer
- How to build an NHL goalie dashboard
- How to build a soccer xG app
- How to build a cricket app
- NFL fantasy football API tutorial
- How to build an NFL scouting tool
- How to build an NFL conditions analytics tool
- NFL betting model API tutorial
- NFL live game center API tutorial
- How to build an NCAAF scoreboard and live game center
- How to build college football rankings and conference standings
- How to build an NCAAF fantasy football app
- How to build an MLB live scoreboard
- How to build a fantasy baseball app
- How to build an MLB pitching dashboard
- How to build an MLB betting model
- How to build an MLB standings dashboard
- How to build a soccer fantasy app
- How to build a soccer betting model
- How to build a soccer live match center
- How to build a soccer player production board
- How to build a soccer fixture alert app
- How to build a soccer scouting tool
- How to build an NCAAF betting model
- How to build an NCAAF conditions analytics tool
- How to build a WNBA live scoreboard
- How to build a WNBA quarter tracker
- How to build a WNBA odds board
- How to build a WNBA schedule browser
- How to build a WNBA team-form tool
- How to build an NCAAB scoreboard
- How to build a March Madness archive
- How to build an NCAAB game-detail view
- How to build an NCAAB team-form dashboard
- How to build an NCAAB head-to-head tool
Known gaps
What the first tracker leaves out
Ship the trustworthy line card before adding portfolio or alerting features.
- No synthetic consensus line when multiple books or markets are absent.
- No automatic bet recommendation derived from a hit rate alone.
- No “live” badge without a freshness state that supports it.
Questions
- Does the route return current prices year-round?
- No. It returns the latest line held for the player. The freshness block tells the client whether that line is live, recent or stale.
- Can a missing line render as zero?
- No. Zero is a possible number; missing means the market is not present. Keep those states distinct.
- Is the rolling hit rate a prediction?
- No. It is historical context computed from the documented sample, not a guarantee about the next game.
- Do full-game odds come with the same Free access?
- No. The exact odds route carries its own Edge plan floor.
Related APIs
Other APIs you can build with: