# The Odds API — how to use (mcp.ai)

Connect your The Odds API account and use 8 tools for gaming straight from your AI agent. Connect with your own API key. The Odds API provides real-time sports betting odds data from various bookmakers worldwide, covering multiple sports and betting markets.

## Option A — via MCP (recommended)
Remote MCP endpoint (HTTP, streamable): `https://api.mcp.ai/p_the_odds_api?ms=1787293440000`
Add it as a custom/remote MCP connector in your client (Claude, Cursor, VS Code…), then authenticate when prompted. Once connected, ask the agent to use the server's tools (e.g. `the_odds_api_get_event_markets`).

## Option B — via direct REST API
Base URL: `https://api.mcp.ai/api/the_odds_api`
Auth: `Authorization: Bearer sk_live_…` — create a workspace API key at https://mcp.ai/settings/api-keys
Discover endpoints: `GET https://api.mcp.ai/api/the_odds_api/_endpoints`

### Endpoints
- `POST https://api.mcp.ai/api/the_odds_api/get/event/markets` — Tool to retrieve available market keys for each bookmaker for a specific event. Returns only recently seen markets - not a comprehensive list. More markets become available as the event's commence tim
  - body: { sport: string, eventId: string, regions: string, bookmakers?: string, dateFormat?: string }
- `POST https://api.mcp.ai/api/the_odds_api/get/event/odds` — Tool to retrieve odds for a specific event. Use after confirming sport key via THE_ODDS_API_GET_SPORTS and event ID via THE_ODDS_API_GET_EVENTS; mismatched values return empty payloads rather than err
  - body: { sport: string, eventId: string, markets?: string, regions?: string, bookmakers?: string, dateFormat?: string, oddsFormat?: string }
- `POST https://api.mcp.ai/api/the_odds_api/get/events` — Tool to fetch live and upcoming events for a specified sport. Use when you need event listings including odds. All timestamps are UTC. Avoid high-frequency polling; batch requests and implement backof
  - body: { sport: string, markets?: string[], regions?: string[], bookmakers?: string[], dateFormat?: string, oddsFormat?: string }
- `POST https://api.mcp.ai/api/the_odds_api/get/odds` — Tool to fetch live and upcoming event odds for a specified sport, including bookmakers, regions, and markets. Use after retrieving sports via GET_SPORTS; filter by region, market, or event IDs. Respon
  - body: { sport: string, markets?: string[], regions: string[], eventIds?: string[], bookmakers?: string[], dateFormat?: string, oddsFormat?: string }
- `POST https://api.mcp.ai/api/the_odds_api/get/participants` — Tool to fetch list of participants (teams or players) for a specified sport. Use after confirming you have a valid sport key.
  - body: { sport: string }
- `POST https://api.mcp.ai/api/the_odds_api/get/scores` — Tool to return live and recently completed event scores for a sport. Use after selecting a sport key to inspect current and recent game scores. Missing results may indicate unsupported competitions, n
  - body: { sport: string, daysFrom?: integer, dateFormat?: string }
- `POST https://api.mcp.ai/api/the_odds_api/get/sports` — Tool to retrieve a list of in-season sports. Use when you need sports data; set 'all' to true to include out-of-season sports. Sport keys returned here must be passed to downstream tools like THE_ODDS
  - body: { all?: boolean }
- `POST https://api.mcp.ai/api/the_odds_api/get/v3/odds` — Tool to fetch odds using the legacy V3 API endpoint. Returns upcoming and live games with odds for a given sport, region, and market. Use for legacy integrations; V4 API is recommended for new impleme
  - body: { mkt?: string, sport: string, region: string, dateFormat?: string, oddsFormat?: string }

## Example prompts
- "What can I do in The Odds API?"
- "Show me a summary of my The Odds API account"

## More
- Page: https://mcp.ai/the_odds_api
- Agent spec (llms.txt): https://mcp.ai/the_odds_api/llms.txt
- Postman collection: https://mcp.ai/the_odds_api/postman.json
