Skip to main content
Glama

Option Contract History

GetOptionContractHistory
Read-only

Get past price and volume bars for ONE option contract by its OCC symbol, active or expired, newest first: open, high, low, close, volume, VWAP and trades. A period without trades has no bar. timeframe is day (default, last 90 days), hour (last 7 days) or minute (last 4 days); startDate and endDate set another window, and history begins in early 2024. Plus receives bars 15 minutes after they end, Pro as they form; the Free plan is answered with an upgrade note. Open interest, greeks and bid/ask have no history; implied volatility history is GetOptionVolatilityHistory. US tickers only.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "ticker": "<ticker>",
      "contract": "<contract>"
    },
    "name": "GetOptionContractHistory"
  }
}

Input Schema

NameRequiredDescriptionDefault
tickerYesUS stock ticker, e.g. AAPL
endDateNoLast date in YYYY-MM-DD format (default: today)
contractYesOCC option symbol, active or expired, e.g. O:AAPL270617C00350000
startDateNoFirst date in YYYY-MM-DD format (default depends on timeframe)
timeframeNoBar size: day, hour or minute (default: day)day
maxResultsNoMaximum bars to return, newest first (default: 60, max: 500)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already establish a safe read-only, closed-world operation, and the description adds substantial behavior beyond them: gaps produce no bar, history starts in early 2024, per-timeframe lookback windows, and delayed vs. real-time delivery by plan with the Free tier returning an upgrade note. The one gap is that the response envelope (paging/metadata) is not characterized, though the field list and newest-first ordering cover most of it.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with purpose and scope, then constraints, then the sibling redirect — a sensible order with almost no filler. It is dense and semicolon-heavy, which costs a point on readability, but every clause carries operational information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a six-parameter historical-bar tool with no output schema, the description covers what is returned, ordering, data availability bounds, rate/tier behavior and market coverage. An agent could call this correctly with no further reading.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline would be 3, but the description adds meaning the schema does not: the default lookback for each timeframe (90/7/4 days), that startDate/endDate override that window, and the earliest available history. That materially reduces the chance of a caller requesting an out-of-range window.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource ("Get past price and volume bars") and immediately narrows scope to "ONE option contract by its OCC symbol, active or expired, newest first." It enumerates the returned fields (OHLC, volume, VWAP, trades) and names the tool that handles a related but different dataset, so an agent can separate it from GetStockPrices, GetOptionTrades and GetOptionVolatilityHistory without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly excludes adjacent data ("Open interest, greeks and bid/ask have no history") and redirects implied-volatility requests to GetOptionVolatilityHistory. It also states access-tier behavior and the US-ticker restriction, leaving little for the agent to infer about when this tool applies.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.