What SportAPI MCP server does
SportAPI MCP server gives MCP-compatible AI assistants read-only access to the SportAPI Sport Line API. It covers live and prematch matches, scores, live statistics, betting odds, sports, countries, tournaments, and competition navigation. The tool set also includes match search, detailed event lookup, highlighted matches and championships, and account-status checks.
The server is suitable for assistants that need to answer questions such as which matches are currently live, when a team plays next, how a market is priced, or which competitions have the most notable fixtures. Results are returned as compact JSON, with empty values removed and odds grouped into concise market lines.
How it works
MCP clients start the package as a local stdio process by default. The server calls the official SportAPI Python client and maps SportAPI methods to tools such as list_live_matches, list_prematch_matches, get_match, search_matches, and top_matches. A Streamable HTTP transport is also available for deployments that need an HTTP endpoint.
Without credentials, tools return documented example responses and label them as demo data. With a key and the matching base URL, the same tools request data available through the account’s SportAPI subscription. Requests use a snapshot cache that follows SportAPI’s documented update intervals and avoids overlapping requests for identical data.
Setup and configuration
Install Python 3.10 or newer and run uvx sportapi-mcp, or install the package with pip and use the sportapi-mcp command. Claude Desktop, Claude Code, Cursor, VS Code, Windsurf, and other MCP clients can launch the stdio server. The repository also documents Docker and Streamable HTTP usage.
Demo mode needs no environment variables. For live data, set SPORTAPI_KEY and SPORTAPI_BASE_URL. SPORTAPI_LANGUAGE is optional and defaults to English; the selected language must be enabled for the key, while demo responses are English only. Use sportapi-mcp --demo to force demo mode even when credentials are present.
Tools and capabilities
The SportAPI MCP server provides these read-only operations:
- List sports with live or prematch availability and counts.
- Browse the sport, country, and tournament menu.
- List countries and tournaments.
- Retrieve live matches or prematch matches by period.
- Fetch detailed match information and filter returned markets.
- Search for matches or teams by text.
- Identify top matches and top championships, optionally with odds.
- Check account status and request information.
A detailed match can contain many markets, so get_match returns a limited selection by default and supports market filters such as 1X2 and Total. The package also includes prompts for a live betting overview and a single-match market comparison covering implied probabilities, bookmaker margin, and fair odds.
Limitations and notes
The SportAPI MCP server does not provide live data without a valid SportAPI account configuration. Demo output comes from SportAPI documentation and must not be treated as current; the server labels its source accordingly. Coverage also depends on the sports and services included in the configured subscription.
SportAPI keys are restricted to approved server IP addresses or sites. The account-status tool can show the IP address seen by SportAPI. Streamable HTTP has no built-in authentication, so it should remain on localhost or be placed behind a gateway that controls access. The server does not poll continuously or fan out requests across matches.