Early access is open. Free sample datasets are live now. Download a sample

API Reference: Options EOD, Bars and Open Interest

Details

Docs navigation

These endpoints return what an option did in the past: one end-of-day record per contract per day with closing quotes and Greeks, intraday bars, and the daily open interest series from OCC. Together they make up the options history API, built for backtesting strategies, charting expired contracts and studying how positioning built up into an expiry.

Early access. Planned v1 endpoints, not live yet. EOD: Free gets 1 year for 5 underlyings a day, Starter ($29/mo) 5 years for all underlyings, Pro ($79/mo) full history. Bars: Starter gets 1-minute bars 15 minutes delayed with 2 years of history, Pro 5 years, Business ($249/mo) full history. Open interest: Free 30 days, Starter 2 years, Pro full.

Pricing

End-of-day prices

GET https://api.marketdata.co/v1/options/eod

Parameters

Name Type Required Default Description
symbol string one of symbol or underlying_symbol OCC contract, e.g. AAPL261218C00230000
underlying_symbol string Every contract on this underlying
date string no One trading day (use with underlying_symbol for a historical chain)
start, end string no Date range
expiration_date string no Filter by expiry
greeks boolean no true Include IV and Greeks
limit, cursor, format no Paging and output

Response fields

Field Type Description
date string Trading date
symbol, underlying_symbol, root_symbol string Contract, underlying, root
expiration_date, strike_price, option_type Contract terms
days_to_expiration integer Calendar days (optional)
open, high, low, close number Trade prices; null when the contract did not trade
volume number Contracts traded
trade_count, vwap number Optional
close_bid, close_ask number Quote at the closing snapshot
close_bid_size, close_ask_size, close_mid number Optional
snapshot_time string When the closing quote was taken, UTC (optional)
open_interest number OCC open interest at start of day
open_interest_change number Change from prior day (optional)
underlying_close number Underlying close
implied_volatility, delta, gamma, theta, vega, rho number At close mid (optional)

Example

Example (curl), the whole SPY chain as it closed on one day:

curl -H "Authorization: Bearer YOUR_API_KEY" \
  "https://api.marketdata.co/v1/options/eod?underlying_symbol=SPY&date=2026-11-18&limit=50000"

Example (Python), one contract's life from listing to expiry:

import os
import requests
import pandas as pd

r = requests.get(
    "https://api.marketdata.co/v1/options/eod",
    headers={"Authorization": f"Bearer {os.environ['MARKETDATA_API_KEY']}"},
    params={"symbol": "AAPL261218C00230000", "start": "2026-01-01"},
)
life = pd.DataFrame(r.json()["results"]).set_index("date")
print(life[["close_mid", "implied_volatility", "delta", "open_interest"]].tail())

Example response row (illustrative):

{
  "date": "2026-11-18",
  "symbol": "AAPL261218C00230000",
  "underlying_symbol": "AAPL",
  "expiration_date": "2026-12-18",
  "strike_price": 230.0,
  "option_type": "call",
  "open": 5.90,
  "high": 6.62,
  "low": 5.81,
  "close": 6.48,
  "volume": 7930,
  "close_bid": 6.45,
  "close_ask": 6.55,
  "close_mid": 6.50,
  "snapshot_time": "2026-11-18T21:00:00Z",
  "open_interest": 21455,
  "underlying_close": 228.61,
  "implied_volatility": 0.270,
  "delta": 0.484
}

Details

Intraday bars

GET https://api.marketdata.co/v1/options/bars

Parameters: symbol (required), interval (1m, 5m, 15m, 1h; default 1m), start, end, limit, cursor, format.

Fields: timestamp (bar start, UTC), interval, symbol, underlying_symbol, open, high, low, close, volume, plus optional trade_count, vwap, close_bid, close_ask and underlying_close.

Details

Open interest

GET https://api.marketdata.co/v1/options/open-interest

Parameters: symbol or underlying_symbol, start, end, and aggregate=true for one row per underlying per day (Pro).

Fields per contract: date, symbol, underlying_symbol, expiration_date, strike_price, option_type, open_interest, previous_open_interest, open_interest_change, open_interest_change_pct, volume, volume_oi_ratio. The aggregate view adds call_open_interest, put_open_interest and put_call_oi_ratio.

API

Errors for these endpoints

HTTP error.code When
400 missing_parameter Neither symbol nor underlying_symbol
400 range_too_large underlying_symbol with a multi-year range; request one date at a time
403 plan_required History or underlyings beyond your plan, aggregate below Pro
404 symbol_not_found Contract never listed

Watch out

Notes and gotchas

  • Use close_mid rather than close for backtests. The last trade can be hours old on illiquid strikes, while the closing quote is taken at one time for every contract.
  • open, high, low and close are null on days with no trades. close_bid and close_ask are still filled.
  • Open interest on date D is the OCC figure published before the open on D, so it reflects positions at the end of D minus 1.
  • Expired contracts stay queryable. Find them with /v1/options/contracts?is_active=false.
  • One underlying for its full history is also sold as a file, from $19 per underlying, with Greeks and IV included. See dataset downloads.

Keep reading

Next steps

Details

Was this page useful?

[Yes] [No]

Need a strategy-level backtest? Tell us on the custom data form.