# Betfair Exchange odds API

Betfair Exchange prices as structured JSON through one REST API.

Betfair Exchange is a betting exchange with the bookmaker key `betfair_exchange`. SockOdds is independent and is not affiliated with or endorsed by Betfair Exchange.

## Leagues

Betfair Exchange prices are delivered for 10 leagues as of 12 October 2026: [Bundesliga](https://sockodds.com/leagues/bundesliga-odds-api/), [English Premier League](https://sockodds.com/leagues/epl-odds-api/), [La Liga](https://sockodds.com/leagues/la-liga-odds-api/), [Ligue 1](https://sockodds.com/leagues/ligue-1-odds-api/), [MLS](https://sockodds.com/leagues/mls-odds-api/), [NBA](https://sockodds.com/leagues/nba-odds-api/), [College football](https://sockodds.com/leagues/ncaaf-odds-api/), [NHL](https://sockodds.com/leagues/nhl-odds-api/), [Rugby League World Cup](https://sockodds.com/leagues/rlwc-odds-api/) and [Serie A](https://sockodds.com/leagues/serie-a-odds-api/).

## Request Betfair Exchange prices

Filter any odds request to Betfair Exchange with `bookmakers=betfair_exchange`:

```bash
curl -sS "https://api.sockodds.com/v1/odds?league=bundesliga&bookmakers=betfair_exchange&markets=result&limit=1&starts_after=$(date -u +%Y-%m-%dT%H:%M:%SZ)" \
  -H "Authorization: Bearer $SOCKODDS_API_KEY"
```

```javascript
const response = await fetch(`https://api.sockodds.com/v1/odds?league=bundesliga&bookmakers=betfair_exchange&markets=result&limit=1&starts_after=${new Date().toISOString().slice(0, 19)}Z`, {
  headers: { Authorization: `Bearer ${process.env.SOCKODDS_API_KEY}` },
});
console.log(JSON.stringify(await response.json(), null, 2));
```

```python
import json, os, urllib.request
from datetime import datetime, timezone

request = urllib.request.Request(
    f"https://api.sockodds.com/v1/odds?league=bundesliga&bookmakers=betfair_exchange&markets=result&limit=1&starts_after={datetime.now(timezone.utc):%Y-%m-%dT%H:%M:%SZ}",
    headers={"Authorization": "Bearer " + os.environ["SOCKODDS_API_KEY"]},
)
with urllib.request.urlopen(request) as response:
    print(json.dumps(json.load(response), indent=2))
```

Response (from a local copy of the API with invented test prices):

```json
{
  "data": [
    {
      "id": "ev_000ckk0f7k5n",
      "name": "Bayer Leverkusen v Bayern Munich",
      "league": {
        "key": "bundesliga",
        "name": "Bundesliga"
      },
      "scheduled_start": "2026-10-16T10:00:00.000Z",
      "status": "scheduled",
      "participants": [
        {
          "role": "away",
          "identity": {
            "key": "bayern_munich",
            "name": "Bayern Munich"
          }
        },
        {
          "role": "home",
          "identity": {
            "key": "bayer_leverkusen",
            "name": "Bayer Leverkusen"
          }
        }
      ],
      "markets": [
        {
          "id": "mk_6j63ysznbx2v7ckt",
          "key": "result",
          "name": "Result (with the draw)",
          "period": "full",
          "subject": null,
          "alternate": false,
          "outcomes": [
            {
              "id": "oc_0ehcc3qwzvxxn8hx",
              "name": "Bayer Leverkusen",
              "side": "home",
              "line": null,
              "prices": [
                {
                  "bookmaker": "betfair_exchange",
                  "decimal_odds": 2.01,
                  "implied_probability": 0.497512,
                  "available": true,
                  "observed_at": "2026-10-15T07:58:00.000Z"
                }
              ]
            },
            {
              "id": "oc_hsye8b66y30abbsz",
              "name": "Draw",
              "side": "draw",
              "line": null,
              "prices": [
                {
                  "bookmaker": "betfair_exchange",
                  "decimal_odds": 3.33,
                  "implied_probability": 0.3003,
                  "available": true,
                  "observed_at": "2026-10-15T07:58:00.000Z"
                }
              ]
            },
            {
              "id": "oc_jhwtphb770vxvg61",
              "name": "Bayern Munich",
              "side": "away",
              "line": null,
              "prices": [
                {
                  "bookmaker": "betfair_exchange",
                  "decimal_odds": 3.53,
                  "implied_probability": 0.283286,
                  "available": true,
                  "observed_at": "2026-10-15T07:58:00.000Z"
                }
              ]
            }
          ]
        }
      ]
    }
  ],
  "meta": {
    "count": 1,
    "cursor": null
  },
  "links": {
    "next": null
  }
}
```

## Plans

Betfair Exchange is included on Rookie and Pro. See [pricing](https://sockodds.com/pricing/) for the bookmakers each plan includes.

## Related

- [Every bookmaker](https://sockodds.com/bookmakers/)
- [Reading prices](https://sockodds.com/docs/odds/)
- [Quickstart](https://sockodds.com/docs/quickstart/)
