Odds comparison API for the best lines
Odds comparison API that returns the best price for every outcome across every sportsbook, exchange and DFS app in one call, with the books that offer it.
Comparing 36 sources client-side means a lot of requests and a lot of code. The best-lines endpoint does the comparison on our side and returns the top price per outcome with the books that post it.
- Top price per outcome across every source
- Ties listed with every book at that price
- Number of books quoting each market
- Filter by book list, market and period
Line shopping is the simplest edge in sports betting and the most tedious one to build: pull every book's price, group the markets that are actually the same, convert prices to one scale and pick the highest. An odds comparison API does that work on the server. PreciseAPI's /v1/best-lines endpoint compares every sportsbook and exchange quoting a market and returns the best price for each outcome, the books offering it and how many books were compared.
This page covers the response, the exact comparison rules, which books and markets are included, what it costs, how it compares with doing the comparison yourself, and how teams build arbitrage and positive EV tools on top of it.
What the odds comparison API returns
GET /v1/best-lines takes a league, or a list of event ids, and returns each event with a markets array. Each market has its key, period and line, the books_quoting count, and an outcome for each side with best_price and best_books.
curl "https://api.preciseapi.com/v1/best-lines?league=nfl&markets=spread,total&periods=full_game,1h&books=draftkings,fanduel,betmgm,caesars,fanatics" \
-H "Authorization: Bearer $PRECISEAPI_KEY"
A trimmed response, with one market:
{
"data": [{
"id": "evt_01a7mgfh0nd",
"league": "nfl",
"start_time": "2026-11-15T18:00:00.000Z",
"status": "scheduled",
"home": { "id": "nfl_jax", "name": "Jacksonville Jaguars", "abbr": "JAX" },
"away": { "id": "nfl_hou", "name": "Houston Texans", "abbr": "HOU" },
"markets": [{
"key": "spread",
"period": "full_game",
"line": -2.5,
"books_quoting": 4,
"outcomes": [
{ "id": "sel_0kovr997gwd", "name": "Jacksonville Jaguars", "side": "home", "point": -2.5, "best_price": -105, "best_books": ["fanduel"] },
{ "id": "sel_00gfnqpn9jj", "name": "Houston Texans", "side": "away", "point": 2.5, "best_price": -108, "best_books": ["betmgm", "caesars"] }
]
}]
}],
"meta": { "count": 1, "credits_used": 3 }
}
best_books lists every book tied at the best price, so a screen can show all of them. best_price follows format: American by default, or decimal and implied probability. Props and team totals also carry the player or team they belong to.
The sample shows why the comparison matters. Best prices of -105 and -108 imply 51.2% and 51.9%, a combined 103.1%, against 104.8% for a standard -110/-110 market at a single book. That difference is margin a bettor doesn't pay, and it is what an odds comparison API exists to surface on every market at once.
How the comparison works
The comparison only puts like with like. Markets are grouped by key, period, player or team, and line, so a spread at -2.5 and a spread at -3 are separate entries, each compared only among the books posting that number. Within a group, the best price is the one with the highest payout, and a market appears only when at least two books quote it. With format=probability, that means the lowest implied probability.
Some prices are left out on purpose: suspended markets, DFS pick'em apps (an entry payout is not a cash price), promotional lines, alternate ladders and one-sided milestone props. Exchanges are included at their quoted price, before any venue fees. markets defaults to moneyline, spread and total for the full game, and periods adds halves, quarters and the rest.
Books, markets and leagues compared
By default every source pricing the event takes part: 23 sportsbooks, from FanDuel, DraftKings and BetMGM to Pinnacle, Circa and BetOnline, plus 7 exchanges such as Novig and Kalshi. Most products narrow it with books, for example to the regulated books available to their users, because a best price at a book your reader can't use isn't useful odds comparison data.
All 17 leagues are supported. Beyond main lines, markets accepts team_total and player_* keys, so the same call answers where the best over on a player's points line is. Up to 200 events come back per call.
Plans and credit cost
One /v1/best-lines call costs 3 credits, on every plan, the free Sandbox included. That replaces a 2-credit /v1/odds call plus your own comparison loop, so the extra credit buys back the code. Edge's 100,000 monthly credits cover about 33,000 calls: polling one league every five minutes uses about 26,000 credits in a 30-day month, and every minute about 130,000, more than Edge includes; Sharp and Syndicate are unlimited, and on Syndicate games in progress are compared too. The Sandbox's 50 one-time credits cover about 16 calls, at 20 requests a minute. See odds API pricing.
Best lines API vs. comparing books yourself
Doing it yourself is reasonable when you need rules of your own, such as weighting books or applying venue fees before comparing. You pull /v1/odds, group by key, period, subject and line, convert to decimal, take the maximum and keep ties, and drop suspended markets. Most teams find the server-side best lines API enough for display and use /v1/odds only where they need every book's number.
Among providers, approaches differ. As checked in October 2026, SharpAPI prices its plans by the number of sportsbooks (5, 15 or 25) and builds EV, no-vig and arbitrage calculations in, while Unabated ships its own vig-free line. A best price odds API from PreciseAPI includes every source on every paid plan and leaves the analysis to you or to the MCP tools. The SharpAPI alternative page sets the two side by side.
From best lines to arbitrage and positive EV
There is no /v1/arbitrage or /v1/ev endpoint. Both are computed from REST data, and best lines is the usual starting point. With format=decimal, a two-way market is an arbitrage when the inverse prices add up to less than 1:
const res = await fetch('https://api.preciseapi.com/v1/best-lines?league=nba&format=decimal', {
headers: { Authorization: `Bearer ${process.env.PRECISEAPI_KEY}` },
});
const { data } = await res.json();
for (const event of data) {
for (const m of event.markets) {
const sum = m.outcomes.reduce((s, o) => s + 1 / o.best_price, 0);
if (m.outcomes.length === 2 && sum < 1) {
console.log(event.away.abbr, '@', event.home.abbr, m.key, m.line ?? '', (100 * (1 - sum)).toFixed(2) + '%',
m.outcomes.map((o) => `${o.name} ${o.best_price} @ ${o.best_books.join('/')}`).join(' | '));
}
}
}
For positive EV, compare each best price with a no-vig fair price from a sharp book or the consensus. In Claude, ChatGPT or Cursor, the find_arbitrage and find_outliers tools on the odds API MCP server run these checks over the same groups. Either way, a result is an observation at the moment of the call: prices move, books limit winning players, and every price should be checked at the book before a bet. PreciseAPI provides data only. The arbitrage API, positive EV API and arbitrage calculator pages go further.
What people build with an odds comparison API
- Line-shopping screens that highlight the best number: real-time odds screen and the line shopping API guide.
- "Best odds" callouts and widgets for publishers: odds API for affiliates and the odds comparison widget post.
- Bots that post the best price across books before a game: odds API for Discord bots.
Every book's individual price, with links to the book, comes from the betting odds API.
Frequently asked questions
Does the odds comparison API include DFS apps?
No. DFS pick'em apps are always left out, because an entry payout is not a cash price. Betting and contract exchanges are included.
Can I limit the comparison to certain books?
Yes. Pass books with the source ids you want, such as books=draftkings,fanduel,betmgm. Only those books are compared, and books_quoting counts only them.
Are alternate lines compared?
No. Alternate spread and total ladders and one-sided milestone props are left out. Main lines, team totals and player props are compared at the same number.
How are ties shown?
best_books lists every book at the best price. A market needs at least two books quoting it to appear at all.
Does it compare games in progress?
On Syndicate, yes: live games are compared with the same rules, using in-play prices. On Edge and Sharp, games in progress are left out of the response, and asking for them with status=live returns a plan error.
How the comparison works
For each market, /v1/best-lines compares every source quoting it at the same line and returns the best price per outcome, the books posting that price, and books_quoting, the number of sources compared. Ties list every book at the best price, and a market needs at least two books to appear. markets defaults to moneyline, spread and total for the full game; periods and books narrow the comparison.
Cost and refresh
One call costs 3 credits and covers up to 200 events, so it replaces a /v1/odds call and your own comparison loop. DFS apps are always left out. Pass the visitor's state for Caesars and BetParx links, and use format=decimal or format=probability to match your audience. Prices for games in progress are included on Syndicate.
Example request
GET /v1/best-lines?league=nba&markets=moneyline,spread,total
Endpoint
- GET /v1/best-lines: Best lines
What teams build with it
- Odds screens: Build a real-time odds screen: every book’s price side by side, the best line highlighted and updates in under a second, from one normalized odds API.
- Media & affiliates: An odds API for affiliates, media and tipsters: live odds tables, best-price widgets and deep links to each book’s bet slip, from one normalized feed.
Related reading
- Line Shopping API: Finding the Best Prices Across Every Book: How to find the best available price for every outcome across sportsbooks and exchanges in code. Matching outcomes, comparing prices and numbers, /v1/best-lines versus computing it yourself, freshness and credit budgets.
- How to Build an Odds Screen in Real Time (Architecture and Code): A production architecture for a live odds screen with a REST snapshot, WebSocket deltas, best-line highlighting in React and handling of stale prices.
- Building an Odds Comparison Widget for Media Sites: An embeddable React widget that shows the best available price per outcome across books, backed by a server-side cache with predictable credit spend, plus compliance notes for publishers.
More products
- Arbitrage API: Arbitrage API data: the best price on every side at identical lines across sportsbooks and exchanges, plus an MCP tool that finds arbs with stakes.
- Positive EV API: Positive EV API data: every book’s price next to the no-vig fair line from the market consensus or a sharp book like Pinnacle, ranked by edge.
- No-vig odds API: No vig odds API data: implied probabilities from every book with format=probability, so you can remove the margin from any market and get fair odds.
- Sports scores API: Sports scores API with live scores, the game clock and final results on the same event ids as the odds, for scoreboards, live screens and bet grading.
Responses use the same event, market and outcome ids as every other endpoint. Prices are American odds by default, with format=decimal and format=probability for the other two, and a market whose source has stopped reporting is flagged suspended instead of being shown as live.
Every source and league is on the coverage page, and what each request costs is on the pricing page.