Football Odds History

v0.2.1
io.github.pipeworx-io/football-odds-history Checked 3 days ago Published 1 month ago

football-odds-history — historical football (soccer) results and odds from sportsbooks, sourced…

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

list_odds_leagues

Lists every football-data.co.uk league code (22 main European leagues with per-season files, 16 extra-league countries with one all-seasons file), with names, countries and the file layout — call before match_odds/team_results to get a valid code.

match_odds

Historical football match results and odds (1X2, over/under 2.5 goals, Asian handicap) from football-data.co.uk, for one league + season. Default response is compact (closing lines from Pinnacle/Bet365/market avg+max, up to 50 matches); pass bookmakers:"all" or raise limit for more detail. Optionally filter by team or date range.

ParameterTypeDescription
league *stringLeague code, e.g. "E0" (Premier League) or "ARG" (Argentina). Call list_odds_leagues for the full list.
bookmakersOptional: "all" for opening+closing odds across every bookmaker, or an array of bookmaker codes (e.g. ["B365","PS"]) for opening+closing on just those. Omit for the compact default — closing-only od…
date_fromstringOptional: ISO date "YYYY-MM-DD", inclusive lower bound.
date_tostringOptional: ISO date "YYYY-MM-DD", inclusive upper bound.
limitnumberMax matches to return, default 50, max 400. Response reports total_matches and truncated so you know if you need to raise this or narrow the filters.
seasonstringRequired for main leagues (22 European divisions): football-data.co.uk's short code "YYZZ" (e.g. "2425" for 2024/25) or "YYYY-YY"/"YYYY/YYYY". Optional for extra-league countries (one file spans all s…
teamstringOptional: only matches involving this team (case-insensitive partial match on home or away).

team_results

A team's football results and odds across one or more seasons of a single football-data.co.uk league, newest first. Default response is compact (closing lines, up to 50 matches); pass bookmakers:"all" or raise limit for more. For a main league with no `seasons` given, searches the 5 most recent seasons; an extra-league country file already spans its whole history.

ParameterTypeDescription
league *stringLeague code, e.g. "E0" or "SP1". Call list_odds_leagues for the full list.
team *stringTeam name, case-insensitive partial match, e.g. "Man United" or "Barcelona".
bookmakersOptional: "all" for opening+closing odds across every bookmaker, or an array of bookmaker codes (e.g. ["B365","PS"]) for opening+closing on just those. Omit for the compact default — closing-only od…
limitnumberMax matches to return, default 50, max 400. Response reports total_matches and truncated so you know if you need to raise this or narrow the filters.
seasonsarrayOptional: specific season codes to search (main-league short codes like "2425", or a year to match against an extra-league Season column). Defaults to the 5 most recent seasons for a main league, or t…