AI-Assisted Development — MCP Server and Context

AI tools speed up development when they have proper context and hallucinate when they don't. The resources below give them the real SockOdds API.

Copy-paste context

We highly recommend you paste the AI context below into your prompt or add it to a rules file.

AI-friendly docs

Indexed documentation

View llms.txt — URLs and descriptions of each documentation page. AI tools can use this to identify which page to fetch.

Length: ~6k tokens

Full documentation

View docs/llms-full.txt — the entire documentation in a single file, for tools with a large context window. llms-full.txt is the full site knowledge payload (sports, leagues, bookmakers, use cases, FAQ, glossary).

Length: ~65k tokens (docs) · ~10k tokens (site payload)

OpenAPI specification

View OpenAPI spec — a machine-readable definition with exact schemas for every endpoint. Every page advertises it via <link rel="service-desc">, so agents can find it without being told the URL.

Length: ~20k tokens

Markdown versions of any page

Every page has a Markdown representation — no HTML, no nav. Request it either way:

# Content negotiation
curl -H "Accept: text/markdown" https://sockodds.com/docs/basics/quickstart

# Or append .md / .mdx to the URL
curl https://sockodds.com/docs/basics/quickstart.mdx
curl https://sockodds.com/leagues/afl-odds-api.md

MCP server

Because SockOdds serves the SportsGameOdds v2 schema, the official sports-odds-api-mcp server works against it: set SPORTS_GAME_ODDS_BASE_URL to https://api.sockodds.com/v2. Version 2.1.0 exposes two tools:

  • execute — runs TypeScript against the SportsGameOdds SDK client (events, odds, teams, players, leagues, markets, usage). It executes in a Deno sandbox on your machine, so Deno must be installed.
  • search_docs — searches the SDK method reference bundled with the server.

Replace your-api-key-here with your key.

Verified against sports-odds-api-mcp@2.1.0 on 7 September 2026: the SDK client reads SPORTS_GAME_ODDS_BASE_URL (not SPORTS_ODDS_API_BASE_URL), and the server passes that base URL into its Deno worker and whitelists only that host for network access. On Deno 2.9 the worker fails to start (NotCapable: requires net access to unix:…deno-http.sock) — against SportsGameOdds' own default URL as well as ours, so it is a bug in the server, not in the override. Until it is fixed, drive the API from an SDK or paste the AI context below.

Claude Code

claude mcp add sockodds --env SPORTS_ODDS_API_KEY_HEADER="your-api-key-here" --env SPORTS_GAME_ODDS_BASE_URL="https://api.sockodds.com/v2" -- npx -y sports-odds-api-mcp
{
  "mcpServers": {
    "sockodds": {
      "command": "npx",
      "args": [
        "-y",
        "sports-odds-api-mcp@latest"
      ],
      "env": {
        "SPORTS_ODDS_API_KEY_HEADER": "your-api-key-here",
        "SPORTS_GAME_ODDS_BASE_URL": "https://api.sockodds.com/v2"
      }
    }
  }
}

Cursor

{
  "mcpServers": {
    "sockodds": {
      "command": "npx",
      "args": [
        "-y",
        "sports-odds-api-mcp@latest"
      ],
      "env": {
        "SPORTS_ODDS_API_KEY_HEADER": "your-api-key-here",
        "SPORTS_GAME_ODDS_BASE_URL": "https://api.sockodds.com/v2"
      }
    }
  }
}

VS Code

code --add-mcp '{"name":"sockodds","command":"npx","args":["-y","sports-odds-api-mcp@latest"],"env":{"SPORTS_ODDS_API_KEY_HEADER":"your-api-key-here","SPORTS_GAME_ODDS_BASE_URL":"https://api.sockodds.com/v2"}}'
{
  "name": "sockodds",
  "command": "npx",
  "args": [
    "-y",
    "sports-odds-api-mcp@latest"
  ],
  "env": {
    "SPORTS_ODDS_API_KEY_HEADER": "your-api-key-here",
    "SPORTS_GAME_ODDS_BASE_URL": "https://api.sockodds.com/v2"
  }
}

AI context

Paste the following into your prompt or rules file:

# SockOdds API Reference

Australian sports odds data in the SportsGameOdds v2 schema.

## Primary documentation resources
If your environment can fetch URLs, use these as sources of truth. **Do not guess or make up information.**
| Resource | URL | Use case |
| --- | --- | --- |
| Documentation index (~6k tokens) | https://sockodds.com/llms.txt | Overview of every documentation page with descriptions |
| Full documentation (~65k tokens) | https://sockodds.com/docs/llms-full.txt | Detailed explanations of fields, parameters and examples |
| OpenAPI specification (~20k tokens) | https://sockodds.com/openapi.json | Exact request/response schemas and parameter definitions |
| Any page as Markdown | append .md to a page URL, or send Accept: text/markdown | Clean prose without HTML — e.g. https://sockodds.com/leagues/afl-odds-api.md |

> Note: if you cannot fetch URLs, ask the user to paste the relevant resource rather than guessing.

## Authentication
- API key required: https://sockodds.com/signup (free tier, shown once). Never invent an API key.
- Header: x-api-key: API_KEY   or   query: ?apiKey=API_KEY

## Base URL
https://api.sockodds.com/v2   (same paths as api.sportsgameodds.com/v2)

## Response format
All responses are JSON: { "success": true, "data": [...], "nextCursor": string|null, "notice": string? }
Errors: { "success": false, "error": "..." } with 400/401/403/429/500.

## Events endpoint (most common)
GET https://api.sockodds.com/v2/events
| Parameter | Example | Description |
| --- | --- | --- |
| oddsAvailable | true | only events with open markets |
| leagueID | AFL,NRL | comma-separated leagues (AFL, AFLW, NRL, RUGBYLEAGUE_NRLW, IPL, EPL, NFL, NBA, MLB, ...) |
| oddID | points-home-game-ml-home | comma-separated markets; PLAYER_ID matches every player |
| includeOpposingOdds | true | also return the other side |
| bookmakerID | sportsbet,tab | limit bookmakers |
| includeAltLines | true | alternate lines (large) |
| cursor / limit | | pagination (limit default 10, max 100) |

### Event object key fields
eventID, sportID, leagueID, type, teams.home.teamID, teams.away.teamID, status.startsAt, status.started, status.ended, status.finalized, status.live, info.stale, info.lastUpdatedAt, players.<playerID>, odds.<oddID>, links.bookmakers, links.betslip

## oddID format
{statID}-{statEntityID}-{periodID}-{betTypeID}-{sideID}
points-home-game-ml-home (head to head, home) · points-all-game-ou-over (total over) · disposals-LACHIE_NEALE_1_AFL-game-ou-over (player prop)

## Bookmaker odds structure
odds.<oddID>.byBookmaker.<bookmakerID>: { odds: "-108" (American string), decimal: 1.93, available: bool, overUnder|spread: string?, lastUpdatedAt }
bookmakerIDs: sportsbet, unibet, tab, playup, tabtouch, betright, neds, picklebet, pointsbet, betdeluxe, betfairexchange, kalshi, polymarket, prophetexchange

## Consensus
odds.<oddID>.bookOdds (with vig) and fairOdds (de-vigged, Base plan and above; null with fairOddsAvailable=false when not computable)

## Not offered
No WebSocket streaming (/v2/stream/events is 501). No open/close snapshots. Poll every 2-5 minutes; cache by info.lastUpdatedAt.
Need help?FAQ · Email · Contact