Historical Closing Odds
Retrieve the closing odds captured for all events on a specific date — the last pre-match price from each sportsbook before a game went live, with Power-devigged no-vig probabilities.
GET /api/v1/historical/odds/closingSharp tier or higher required. Pro and lower tiers receive a 403 tier_restricted error. This endpoint is gated by the closing_lines feature.
Phase 1 data window: Closing lines are captured in real-time on isLive false→true transitions. Valkey retains 30 days of data. Requesting a date older than 30 days will return an empty result.
Authentication
Requires API key. Sharp tier or higher required (closing_lines feature).
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
date | string | Yes | Date in YYYY-MM-DD format (UTC). |
sport | string | Yes | Sport identifier, e.g. basketball, football, ice_hockey. |
league | string | Yes | League identifier, e.g. nba, nfl, nhl. |
All three parameters are required. The response is filtered to events matching the exact sport and league on that UTC date.
Date Window
Sharp tier allows up to 30 days of lookback. Requesting a date beyond your tier window returns a 403 tier_restricted error with the allowed window size.
Example Requests
cURL
# NBA closing lines for April 10
curl -X GET "https://api.sharpapi.io/api/v1/historical/odds/closing?date=2026-04-10&sport=basketball&league=nba" \
-H "X-API-Key: YOUR_API_KEY"
# NFL closing lines
curl -X GET "https://api.sharpapi.io/api/v1/historical/odds/closing?date=2026-04-06&sport=football&league=nfl" \
-H "X-API-Key: YOUR_API_KEY"Response
Success (200)
{
"success": true,
"data": {
"date": "2026-04-10",
"sport": "basketball",
"league": "nba",
"events": [
{
"event_id": "evt_nba_bos_mia_20260410",
"sport": "basketball",
"league": "nba",
"home_team": "Boston Celtics",
"away_team": "Miami Heat",
"event_start_time": "2026-04-10T18:00:00Z",
"first_captured_at": "2026-04-10T17:58:12.000000000Z",
"books": [
{
"book": "pinnacle",
"captured_at": "2026-04-10T17:58:12.000000000Z",
"lines": [
{
"market_type": "moneyline",
"selection": "Boston Celtics",
"selection_type": "home",
"line": null,
"odds_american": -145,
"odds_decimal": 1.690,
"implied_probability": 0.5920,
"no_vig_probability": 0.5813
},
{
"market_type": "moneyline",
"selection": "Miami Heat",
"selection_type": "away",
"line": null,
"odds_american": 125,
"odds_decimal": 2.250,
"implied_probability": 0.4444,
"no_vig_probability": 0.4187
},
{
"market_type": "point_spread",
"selection": "Boston Celtics",
"selection_type": "home",
"line": -3.5,
"odds_american": -110,
"odds_decimal": 1.909,
"implied_probability": 0.5238,
"no_vig_probability": 0.5000
}
]
},
{
"book": "draftkings",
"captured_at": "2026-04-10T17:57:44.000000000Z",
"lines": [
{
"market_type": "moneyline",
"selection": "Boston Celtics",
"selection_type": "home",
"line": null,
"odds_american": -140,
"odds_decimal": 1.714,
"implied_probability": 0.5833,
"no_vig_probability": 0.5730
},
{
"market_type": "moneyline",
"selection": "Miami Heat",
"selection_type": "away",
"line": null,
"odds_american": 118,
"odds_decimal": 2.180,
"implied_probability": 0.4587,
"no_vig_probability": 0.4270
}
]
}
]
}
],
"total_events": 5,
"total_lines": 48
},
"meta": {
"source": "valkey:closing_line",
"tier_window_days": 30,
"filters": {
"sport": "basketball",
"league": "nba",
"date": "2026-04-10"
},
"updated_at": "2026-04-17T20:00:00.000000000Z"
}
}Error Responses
400 Validation Error
{
"error": {
"code": "validation_error",
"message": "date parameter is required in YYYY-MM-DD format"
}
}403 Tier Restricted (wrong tier)
{
"error": {
"code": "tier_restricted",
"message": "The 'closing_lines' feature requires Sharp or higher.",
"required_tier": "sharp",
"docs": "https://docs.sharpapi.io/en/pricing"
}
}403 Tier Restricted (date too old)
{
"error": {
"code": "tier_restricted",
"message": "Your sharp plan allows historical data up to 30 days back",
"tier": "sharp",
"docs": "https://sharpapi.io/pricing"
}
}Response Fields
data object
| Field | Type | Description |
|---|---|---|
date | string | The requested date (YYYY-MM-DD) |
sport | string | Sport filter applied |
league | string | League filter applied |
events | array | Closing line events matching the date, sport, and league |
total_events | integer | Number of events in the response |
total_lines | integer | Total number of individual closing lines across all events and books |
Event object
| Field | Type | Description |
|---|---|---|
event_id | string | Unique event identifier |
sport | string | Sport |
league | string | League |
home_team | string | Home team name |
away_team | string | Away team name |
event_start_time | string | ISO 8601 scheduled start time |
first_captured_at | string | ISO 8601 timestamp of the first closing line capture for this event |
books | array | Per-book closing line payloads |
Book object
| Field | Type | Description |
|---|---|---|
book | string | Sportsbook identifier |
captured_at | string | ISO 8601 timestamp when this book’s closing line was captured |
lines | array | Array of closing line entries for this book |
Closing line entry
| Field | Type | Description |
|---|---|---|
market_type | string | Market type: moneyline, point_spread, total_points, etc. |
selection | string | Selection label (team name, Over/Under, player) |
selection_type | string | home, away, over, under, etc. |
line | number|null | Spread or total value (-3.5, 220.5). null for moneylines. |
player_name | string | Player name for player props (omitted otherwise) |
stat_category | string | Stat type for player props (omitted otherwise) |
odds_american | integer | American odds at close |
odds_decimal | number | Decimal odds at close |
implied_probability | number | Raw implied probability (with vig) |
no_vig_probability | number|null | Power-devigged fair probability (0.0–1.0). Present for 2- and 3-way markets; null for single-selection markets. |
timestamp | string | ISO 8601 timestamp of the odds record used for capture |
meta object
| Field | Type | Description |
|---|---|---|
source | string | Always "valkey:closing_line" (Phase 1 backend) |
tier_window_days | integer | Maximum lookback days for your tier (Sharp = 30) |
updated_at | string | ISO 8601 response timestamp |
Use Cases
CLV analysis: Compare no_vig_probability values across books against Pinnacle. A soft book with a higher no_vig_probability on the favorite closed looser — positive CLV for bettors who took that side.
Line shopping audit: Retrieve closing lines across all books to understand where value was available at close.
Model calibration: Use implied_probability and no_vig_probability as historical ground truth for calibrating your own probability models.
Related Endpoints
- Closing Line Value (CLV) — Aggregate CLV% rollups grouped by sportsbook, sport, league, or day
- Odds Snapshot — Current real-time odds
- +EV Opportunities — Real-time positive expected value bets