> ## Documentation Index
> Fetch the complete documentation index at: https://docs.corsair.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# The Odds API API reference

> API reference for the The Odds API plugin in Corsair: every `theoddsapi.api.*` operation with its input and output types, taken from the plugin's Zod schemas.

> [!NOTE]
>
> **New to Corsair?** See [API access](https://docs.corsair.dev/concepts/api.md), [authentication](https://docs.corsair.dev/concepts/auth.md), and [error handling](https://docs.corsair.dev/concepts/error-handling).

## Events

### list

`events.list`

List live and upcoming events for a sport (id, teams, start time) without odds. Free: costs no usage credits.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.events.list({ sport: 'basketball_nba' });
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `dateFormat` | `iso \| unix` | No | — |
| `eventIds` | `string` | No | Comma-separated event ids to keep. |
| `commenceTimeFrom` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `commenceTimeTo` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `includeRotationNumbers` | `boolean` | No | — |

**Output:** `object[]`

> [accordion] Output full type
>
> ```ts theme={null}
> {
>   id: string,
>   sport_key?: string | null,
>   sport_title?: string | null,
>   commence_time?: string | number | null,
>   home_team?: string | null,
>   away_team?: string | null,
>   home_rotation?: number | string | null,
>   away_rotation?: number | string | null
> }[]
> ```

***

### markets

`events.markets`

List the market keys each bookmaker currently offers for one event. Costs 1 credit.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.events.markets({ sport: 'basketball_nba', eventId: '<id of an upcoming NBA event from events.list>', regions: 'us' });
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `eventId` | `string` | Yes | Event id from events.list or odds.get. |
| `regions` | `string` | No | Comma-separated bookmaker regions: `us`, `us2`, `us_dfs`, `us_ex`, `uk`, `eu`, `au`, `ca`, `de`, `fr`, `se`, `fi`. Each region multiplies the cost. |
| `bookmakers` | `string` | No | Comma-separated bookmaker keys (`draftkings,fanduel`); takes priority over regions. Every 10 bookmakers cost as one region. |
| `dateFormat` | `iso \| unix` | No | — |

Pass `regions` or `bookmakers` (at least one). Each is optional on its own, but the call is refused without either.

**Output**

| Name | Type | Required | Description |
| - | - | - | - |
| `id` | `string` | Yes | — |
| `sport_key` | `string \| null` | No | — |
| `sport_title` | `string \| null` | No | — |
| `commence_time` | `string \| number \| null` | No | — |
| `home_team` | `string \| null` | No | — |
| `away_team` | `string \| null` | No | — |
| `home_rotation` | `number \| string \| null` | No | — |
| `away_rotation` | `number \| string \| null` | No | — |
| `bookmakers` | `object[] \| null` | No | — |

> [accordion] bookmakers full type
>
> ```ts theme={null}
> {
>   key: string,
>   title?: string | null,
>   last_update?: string | number | null,
>   link?: string | null,
>   sid?: string | null,
>   markets?: {
>     key: string,
>     last_update?: string | number | null,
>     link?: string | null,
>     sid?: string | null,
>     outcomes?: {
>       name?: string | null,
>       price?: number | null,
>       point?: number | null,
>       description?: string | null,
>       link?: string | null,
>       sid?: string | null,
>       bet_limit?: number | null,
>       multiplier?: number | null
>     }[] | null
>   }[] | null
> }[] | null
> ```

***

### odds

`events.odds`

Get one event's odds for any market, including player props and alternate lines. Costs 1 credit per market returned per region.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.events.odds({
	sport: 'americanfootball_nfl',
	eventId: '<id of an upcoming NFL event from events.list>',
	regions: 'us',
	markets: 'player_pass_tds',
});
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `eventId` | `string` | Yes | Event id from events.list or odds.get. |
| `regions` | `string` | No | Comma-separated bookmaker regions: `us`, `us2`, `us_dfs`, `us_ex`, `uk`, `eu`, `au`, `ca`, `de`, `fr`, `se`, `fi`. Each region multiplies the cost. |
| `markets` | `string` | No | Comma-separated market keys; any market is accepted here (`h2h,player_points,alternate_spreads`). |
| `dateFormat` | `iso \| unix` | No | — |
| `oddsFormat` | `decimal \| american` | No | — |
| `bookmakers` | `string` | No | Comma-separated bookmaker keys (`draftkings,fanduel`); takes priority over regions. Every 10 bookmakers cost as one region. |
| `includeLinks` | `boolean` | No | — |
| `includeSids` | `boolean` | No | — |
| `includeBetLimits` | `boolean` | No | — |
| `includeMultipliers` | `boolean` | No | — |
| `includeRotationNumbers` | `boolean` | No | — |

Pass `regions` or `bookmakers` (at least one). Each is optional on its own, but the call is refused without either.

**Output**

| Name | Type | Required | Description |
| - | - | - | - |
| `id` | `string` | Yes | — |
| `sport_key` | `string \| null` | No | — |
| `sport_title` | `string \| null` | No | — |
| `commence_time` | `string \| number \| null` | No | — |
| `home_team` | `string \| null` | No | — |
| `away_team` | `string \| null` | No | — |
| `home_rotation` | `number \| string \| null` | No | — |
| `away_rotation` | `number \| string \| null` | No | — |
| `bookmakers` | `object[] \| null` | No | — |

> [accordion] bookmakers full type
>
> ```ts theme={null}
> {
>   key: string,
>   title?: string | null,
>   last_update?: string | number | null,
>   link?: string | null,
>   sid?: string | null,
>   markets?: {
>     key: string,
>     last_update?: string | number | null,
>     link?: string | null,
>     sid?: string | null,
>     outcomes?: {
>       name?: string | null,
>       price?: number | null,
>       point?: number | null,
>       description?: string | null,
>       link?: string | null,
>       sid?: string | null,
>       bet_limit?: number | null,
>       multiplier?: number | null
>     }[] | null
>   }[] | null
> }[] | null
> ```

***

## Historical

### eventMarkets

`historical.eventMarkets`

List the market keys each bookmaker offered for one event at a past time (the event must have existed then; take its id from historical.events). Costs 1 credit; answered on a free key in our 12-02 test.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.historical.eventMarkets({
	sport: 'basketball_nba',
	eventId: 'bbde7751a144b98ed150d7a5f7dc8f87',
	regions: 'us',
	date: '2025-10-18T12:00:00Z',
});
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `eventId` | `string` | Yes | Event id from events.list or odds.get. |
| `regions` | `string` | No | Comma-separated bookmaker regions: `us`, `us2`, `us_dfs`, `us_ex`, `uk`, `eu`, `au`, `ca`, `de`, `fr`, `se`, `fi`. Each region multiplies the cost. |
| `bookmakers` | `string` | No | Comma-separated bookmaker keys (`draftkings,fanduel`); takes priority over regions. Every 10 bookmakers cost as one region. |
| `dateFormat` | `iso \| unix` | No | — |
| `date` | `string` | Yes | ISO 8601 time of the snapshot; the closest snapshot at or before it is returned (`2025-10-18T12:00:00Z`). |

Pass `regions` or `bookmakers` (at least one). Each is optional on its own, but the call is refused without either.

**Output**

| Name | Type | Required | Description |
| - | - | - | - |
| `timestamp` | `string \| number \| null` | No | — |
| `previous_timestamp` | `string \| number \| null` | No | — |
| `next_timestamp` | `string \| number \| null` | No | — |
| `data` | `object` | Yes | — |

> [accordion] data full type
>
> ```ts theme={null}
> {
>   id: string,
>   sport_key?: string | null,
>   sport_title?: string | null,
>   commence_time?: string | number | null,
>   home_team?: string | null,
>   away_team?: string | null,
>   home_rotation?: number | string | null,
>   away_rotation?: number | string | null,
>   bookmakers?: {
>     key: string,
>     title?: string | null,
>     last_update?: string | number | null,
>     link?: string | null,
>     sid?: string | null,
>     markets?: {
>       key: string,
>       last_update?: string | number | null,
>       link?: string | null,
>       sid?: string | null,
>       outcomes?: {
>         name?: string | null,
>         price?: number | null,
>         point?: number | null,
>         description?: string | null,
>         link?: string | null,
>         sid?: string | null,
>         bet_limit?: number | null,
>         multiplier?: number | null
>       }[] | null
>     }[] | null
>   }[] | null
> }
> ```

***

### eventOdds

`historical.eventOdds`

Get one event's odds for any market as they were at a past time (take the event id from historical.events). Paid plans only; costs 10 credits per market returned per region.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.historical.eventOdds({
	sport: 'basketball_nba',
	eventId: 'bbde7751a144b98ed150d7a5f7dc8f87',
	regions: 'us',
	date: '2025-10-18T12:00:00Z',
});
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `eventId` | `string` | Yes | Event id from events.list or odds.get. |
| `regions` | `string` | No | Comma-separated bookmaker regions: `us`, `us2`, `us_dfs`, `us_ex`, `uk`, `eu`, `au`, `ca`, `de`, `fr`, `se`, `fi`. Each region multiplies the cost. |
| `markets` | `string` | No | Comma-separated market keys; any market is accepted here (`h2h,player_points,alternate_spreads`). |
| `dateFormat` | `iso \| unix` | No | — |
| `oddsFormat` | `decimal \| american` | No | — |
| `bookmakers` | `string` | No | Comma-separated bookmaker keys (`draftkings,fanduel`); takes priority over regions. Every 10 bookmakers cost as one region. |
| `includeLinks` | `boolean` | No | — |
| `includeSids` | `boolean` | No | — |
| `includeBetLimits` | `boolean` | No | — |
| `includeMultipliers` | `boolean` | No | — |
| `includeRotationNumbers` | `boolean` | No | — |
| `date` | `string` | Yes | ISO 8601 time of the snapshot; the closest snapshot at or before it is returned (`2025-10-18T12:00:00Z`). |

Pass `regions` or `bookmakers` (at least one). Each is optional on its own, but the call is refused without either.

**Output**

| Name | Type | Required | Description |
| - | - | - | - |
| `timestamp` | `string \| number \| null` | No | — |
| `previous_timestamp` | `string \| number \| null` | No | — |
| `next_timestamp` | `string \| number \| null` | No | — |
| `data` | `object` | Yes | — |

> [accordion] data full type
>
> ```ts theme={null}
> {
>   id: string,
>   sport_key?: string | null,
>   sport_title?: string | null,
>   commence_time?: string | number | null,
>   home_team?: string | null,
>   away_team?: string | null,
>   home_rotation?: number | string | null,
>   away_rotation?: number | string | null,
>   bookmakers?: {
>     key: string,
>     title?: string | null,
>     last_update?: string | number | null,
>     link?: string | null,
>     sid?: string | null,
>     markets?: {
>       key: string,
>       last_update?: string | number | null,
>       link?: string | null,
>       sid?: string | null,
>       outcomes?: {
>         name?: string | null,
>         price?: number | null,
>         point?: number | null,
>         description?: string | null,
>         link?: string | null,
>         sid?: string | null,
>         bet_limit?: number | null,
>         multiplier?: number | null
>       }[] | null
>     }[] | null
>   }[] | null
> }
> ```

***

### events

`historical.events`

List a sport's events as they were at a past time, without odds, with the previous and next snapshot times. Costs 1 credit (nothing when empty); answered on a free key in our 12-02 test.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.historical.events({ sport: 'basketball_nba', date: '2025-10-18T12:00:00Z' });
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `dateFormat` | `iso \| unix` | No | — |
| `eventIds` | `string` | No | Comma-separated event ids to keep. |
| `commenceTimeFrom` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `commenceTimeTo` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `includeRotationNumbers` | `boolean` | No | — |
| `date` | `string` | Yes | ISO 8601 time of the snapshot; the closest snapshot at or before it is returned (`2025-10-18T12:00:00Z`). |

**Output**

| Name | Type | Required | Description |
| - | - | - | - |
| `timestamp` | `string \| number \| null` | No | — |
| `previous_timestamp` | `string \| number \| null` | No | — |
| `next_timestamp` | `string \| number \| null` | No | — |
| `data` | `object[]` | Yes | — |

> [accordion] data full type
>
> ```ts theme={null}
> {
>   id: string,
>   sport_key?: string | null,
>   sport_title?: string | null,
>   commence_time?: string | number | null,
>   home_team?: string | null,
>   away_team?: string | null,
>   home_rotation?: number | string | null,
>   away_rotation?: number | string | null
> }[]
> ```

***

### odds

`historical.odds`

Get a sport's odds as they were at a past time (snapshots every 5-10 minutes since June 2020), with the previous and next snapshot times. Paid plans only; costs 10 credits per market per region.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.historical.odds({
	sport: 'basketball_nba',
	regions: 'us',
	markets: 'h2h',
	date: '2025-10-18T12:00:00Z',
});
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `regions` | `string` | No | Comma-separated bookmaker regions: `us`, `us2`, `us_dfs`, `us_ex`, `uk`, `eu`, `au`, `ca`, `de`, `fr`, `se`, `fi`. Each region multiplies the cost. |
| `markets` | `string` | No | Comma-separated market keys. Featured markets: `h2h`, `spreads`, `totals`, `outrights` (default `h2h`). Each market multiplies the cost. |
| `dateFormat` | `iso \| unix` | No | — |
| `oddsFormat` | `decimal \| american` | No | — |
| `eventIds` | `string` | No | Comma-separated event ids to keep. |
| `bookmakers` | `string` | No | Comma-separated bookmaker keys (`draftkings,fanduel`); takes priority over regions. Every 10 bookmakers cost as one region. |
| `commenceTimeFrom` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `commenceTimeTo` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `includeLinks` | `boolean` | No | — |
| `includeSids` | `boolean` | No | — |
| `includeBetLimits` | `boolean` | No | — |
| `includeRotationNumbers` | `boolean` | No | — |
| `date` | `string` | Yes | ISO 8601 time of the snapshot; the closest snapshot at or before it is returned (`2025-10-18T12:00:00Z`). |

Pass `regions` or `bookmakers` (at least one). Each is optional on its own, but the call is refused without either.

**Output**

| Name | Type | Required | Description |
| - | - | - | - |
| `timestamp` | `string \| number \| null` | No | — |
| `previous_timestamp` | `string \| number \| null` | No | — |
| `next_timestamp` | `string \| number \| null` | No | — |
| `data` | `object[]` | Yes | — |

> [accordion] data full type
>
> ```ts theme={null}
> {
>   id: string,
>   sport_key?: string | null,
>   sport_title?: string | null,
>   commence_time?: string | number | null,
>   home_team?: string | null,
>   away_team?: string | null,
>   home_rotation?: number | string | null,
>   away_rotation?: number | string | null,
>   bookmakers?: {
>     key: string,
>     title?: string | null,
>     last_update?: string | number | null,
>     link?: string | null,
>     sid?: string | null,
>     markets?: {
>       key: string,
>       last_update?: string | number | null,
>       link?: string | null,
>       sid?: string | null,
>       outcomes?: {
>         name?: string | null,
>         price?: number | null,
>         point?: number | null,
>         description?: string | null,
>         link?: string | null,
>         sid?: string | null,
>         bet_limit?: number | null,
>         multiplier?: number | null
>       }[] | null
>     }[] | null
>   }[] | null
> }[]
> ```

***

## Odds

### get

`odds.get`

Get live and upcoming games for a sport with each bookmaker's prices for the chosen markets (h2h, spreads, totals, outrights) and regions. Costs 1 credit per market per region; an empty result costs nothing.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.odds.get({ sport: 'basketball_nba', regions: 'us', markets: 'h2h' });
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `regions` | `string` | No | Comma-separated bookmaker regions: `us`, `us2`, `us_dfs`, `us_ex`, `uk`, `eu`, `au`, `ca`, `de`, `fr`, `se`, `fi`. Each region multiplies the cost. |
| `markets` | `string` | No | Comma-separated market keys. Featured markets: `h2h`, `spreads`, `totals`, `outrights` (default `h2h`). Each market multiplies the cost. |
| `dateFormat` | `iso \| unix` | No | — |
| `oddsFormat` | `decimal \| american` | No | — |
| `eventIds` | `string` | No | Comma-separated event ids to keep. |
| `bookmakers` | `string` | No | Comma-separated bookmaker keys (`draftkings,fanduel`); takes priority over regions. Every 10 bookmakers cost as one region. |
| `commenceTimeFrom` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `commenceTimeTo` | `string` | No | ISO 8601 time such as `2026-12-01T00:00:00Z`. |
| `includeLinks` | `boolean` | No | — |
| `includeSids` | `boolean` | No | — |
| `includeBetLimits` | `boolean` | No | — |
| `includeRotationNumbers` | `boolean` | No | — |

Pass `regions` or `bookmakers` (at least one). Each is optional on its own, but the call is refused without either.

**Output:** `object[]`

> [accordion] Output full type
>
> ```ts theme={null}
> {
>   id: string,
>   sport_key?: string | null,
>   sport_title?: string | null,
>   commence_time?: string | number | null,
>   home_team?: string | null,
>   away_team?: string | null,
>   home_rotation?: number | string | null,
>   away_rotation?: number | string | null,
>   bookmakers?: {
>     key: string,
>     title?: string | null,
>     last_update?: string | number | null,
>     link?: string | null,
>     sid?: string | null,
>     markets?: {
>       key: string,
>       last_update?: string | number | null,
>       link?: string | null,
>       sid?: string | null,
>       outcomes?: {
>         name?: string | null,
>         price?: number | null,
>         point?: number | null,
>         description?: string | null,
>         link?: string | null,
>         sid?: string | null,
>         bet_limit?: number | null,
>         multiplier?: number | null
>       }[] | null
>     }[] | null
>   }[] | null
> }[]
> ```

***

### legacy

`odds.legacy`

Get odds from the legacy v3 API (`/v3/odds`, one region and market). Prefer odds.get; kept for callers still on v3. Costs 1 credit.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.odds.legacy({ sport: 'basketball_nba', region: 'us', mkt: 'h2h' });
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `region` | `string` | Yes | — |
| `mkt` | `string` | No | — |
| `dateFormat` | `iso \| unix` | No | — |
| `oddsFormat` | `decimal \| american` | No | — |

**Output**

| Name | Type | Required | Description |
| - | - | - | - |
| `success` | `boolean` | No | — |
| `data` | `object[]` | Yes | — |

> [accordion] data full type
>
> ```ts theme={null}
> {
>   id?: string | null,
>   sport_key?: string | null,
>   sport_nice?: string | null,
>   teams?: string[] | null,
>   home_team?: string | null,
>   commence_time?: string | number | null,
>   sites_count?: number | null,
>   sites?: Record<string, any>[] | null
> }[]
> ```

***

## Participants

### list

`participants.list`

List the teams or players of a sport (id and full name). Costs 1 credit.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.participants.list({ sport: 'basketball_nba' });
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |

**Output:** `object[]`

> [accordion] Output full type
>
> ```ts theme={null}
> {
>   id: string,
>   full_name?: string | null
> }[]
> ```

***

## Scores

### get

`scores.get`

Get live, upcoming and (with daysFrom 1-3) recently completed games for a sport with their scores. Costs 1 credit, or 2 with daysFrom.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.scores.get({ sport: 'basketball_nba', daysFrom: 1 });
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `sport` | `string` | Yes | Sport key from sports.list (`basketball_nba`, `soccer_epl`), or `upcoming` for the next games across all sports. |
| `daysFrom` | `number` | No | — |
| `dateFormat` | `iso \| unix` | No | — |
| `eventIds` | `string` | No | Comma-separated event ids to keep. |

**Output:** `object[]`

> [accordion] Output full type
>
> ```ts theme={null}
> {
>   id: string,
>   sport_key?: string | null,
>   sport_title?: string | null,
>   commence_time?: string | number | null,
>   home_team?: string | null,
>   away_team?: string | null,
>   home_rotation?: number | string | null,
>   away_rotation?: number | string | null,
>   completed?: boolean | null,
>   scores?: {
>     name?: string | null,
>     score?: string | number | null
>   }[] | null,
>   last_update?: string | number | null
> }[]
> ```

***

## Sports

### list

`sports.list`

List sports and leagues with their keys (in season only unless all is true). Free: costs no usage credits.

**Risk:** `read`

```ts theme={null}
await corsair.theoddsapi.api.sports.list({});
```

**Input**

| Name | Type | Required | Description |
| - | - | - | - |
| `all` | `boolean` | No | — |

**Output:** `object[]`

> [accordion] Output full type
>
> ```ts theme={null}
> {
>   key: string,
>   active?: boolean | null,
>   group?: string | null,
>   description?: string | null,
>   title?: string | null,
>   has_outrights?: boolean | null
> }[]
> ```

***


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.