Notable changes to this package. Versions follow semantic versioning.
find_arbitrage and find_value_bets now work on markets carrying a line.
Breaking: find_value_bets takes devig where it took sharp, and
window_hours is gone from group_games, find_arbitrage and
find_value_bets.
- Totals, handicaps, team totals and player props are supported. Outcomes are grouped into individual bets before being paired, so Over 8.5 is never matched against Under 9.5, one player's prop never against another's, and one team's total never against the other team's
- Handicaps pair a team against its opponent on the mirrored line. Books
disagree on who is giving start, so
-1.5and+1.5on the same number are two separate bets and backing the same side at two books is not an arb - Which kind of market a response holds is read from the outcomes themselves, not from a list of market keys, so a market the API adds later works without an SDK release
ArbLegandValueBetcarrypointon any market with a line,player_nameon player props andteam_nameon team totals. Head to head results are unchanged, since none of the three applies- One result per line, so a totals market with ten lines can return ten
find_arbitrageno longer discards pairs whose implied probabilities sum to 1 or more, leavingmin_profitas the only filter, so a negative value now shows near misses. At the default of 0.0 the only new result is a pair summing to exactly 1, reported as a 0% arbfind_value_betstakesdevigin place ofsharp, and the fair price can now come from more than one book.devig="Pinnacle"is the old behaviour,devig="all"averages every book in the response, anddevig={"Pinnacle": 0.8, "TAB": 0.2}averages the books you name at your own weights. Each book is de-vigged on its own before the fair odds are averaged, weighted by1 / (1 + margin) ** 2unless you supply weightsmin_booksonfind_value_bets, four by default, is how many books have to price a bet before a consensus is trusted. Naming books lowers it to the number named. It does not apply when de-vigging a single book- Under a consensus no book is excluded from the results, so both sides of a game can show value at once. A single book is still excluded, since it cannot beat its own price
find_value_betsskips a book whose own two prices sum to under 1. That is the book arbing itself, which is a bad feed rather than a thin margin, and normalising it would have invented edge at every other book- Under a consensus, a fair price outside 1.1 to 50, or an edge over 50%, is discarded as bad data. One stale price drags an average in a way it cannot drag a single book's de-vig, so these bounds apply to consensus only
- A handicap outcome naming neither team is ignored. Books disagree on team names, and one quoting the Oakland Athletics as "Athletics" would otherwise read as a third side and make every line of that game unpairable
- A handicap of zero is ignored. It pushes when the teams finish level, so both sides come back rather than one winning, and the pair is not a locked profit
- Only three-way markets now raise
ValidationError, recognised by a draw or tie among the outcomes rather than by counting them. A bet left with more than two sides for any other reason is skipped, so one book's naming cannot take down a whole market - The window for matching a game across bookmakers now comes from the sport,
and
window_hoursis gone fromgroup_games,find_arbitrageandfind_value_bets. MLB gets 1.8 hours and everything else 6, inMATCH_WINDOW_HOURS. The old flat 4 hours merged a split doubleheader starting three hours after the first game, which compared prices across two different games.match_windowreports what a response will get
Four methods for things the API can now answer directly. None of them cost credits, and all need the API at v1.1.0 or later.
list_sportsandget_sport, which return the sports the API accepts and, on request, each one's market keys. The market keys are whatget_oddstakes asmarket_types, so they no longer have to be looked up by handlist_results_sportsfor the sports carrying live scores and player statsget_usagefor the credit balance the server holds. Unlikecredits_usedit survives restarts and counts spend from anywhere, not just this clientSportInfo,SportMarketsandUsageresponse types
The sport tuples in constants stay as an offline snapshot, and BOOKMAKERS
remains the only list of bookmaker feeds, since the API has no endpoint for
them.
First release.
RapidOddsAPIandAsyncRapidOddsAPIclients over RESTget_oddsandget_results, with full type hints on every responsestream_oddsandstream_resultsover WebSocket, with automatic reconnect and re-subscribefind_arbitrageandfind_value_betsfor two-way head to head marketsgroup_gamesto match a game across bookmakers on teams plus a time windowparse_timefor the API's naive UTC timestamps- Typed exceptions, including separate classes for rate limiting and running out of credits
- Automatic retry with backoff on 5xx, rate limits and network failures
credits_usedtally per client