Skip to main content
Glama

get_historical

Retrieve OHLCV historical price data for any stock or index globally with customizable time range and interval. Supports US, NSE, BSE, and major indices.

Instructions

Get OHLCV historical price data for any stock or index globally. Supports US stocks (AAPL), NSE stocks (RELIANCE.NS), BSE stocks (HDFCBANK.BO), and indices (^NSEI, ^GSPC). Range: 1d, 5d, 1mo, 3mo, 6mo, 1y, 2y, 5y, 10y, ytd, max Interval: 1m, 5m, 15m, 30m, 1h, 1d, 1wk, 1mo

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
rangeNoTime range (default: 3mo)3mo
symbolYesTicker symbol (e.g. TCS.NS, AAPL, ^NSEI)
intervalNoBar interval (default: 1d)1d
Behavior2/5

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

With no annotations, the description should disclose behavioral traits. It only lists input options and does not mention data sources, rate limits, error handling, or what happens with invalid symbols.

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

Conciseness5/5

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

The description is concise (three sentences) and front-loaded with the primary purpose. Every sentence adds value without redundancy.

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

Completeness3/5

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

Given the absence of an output schema, the description does not specify the structure of the returned OHLCV data (e.g., columns, timestamp format). It covers input well but lacks output details, which is a gap for a data retrieval tool.

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?

The schema already covers all parameters with descriptions. The description adds value by providing real-world examples of supported stock suffixes and index prefixes, which clarifies how to use the symbol parameter beyond the schema.

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 clearly states the tool retrieves OHLCV historical price data for stocks and indices globally. It distinguishes itself from sibling tools like get_quote (current price) and get_nse_historical (NSE-specific) by its broad coverage and focus on historical data.

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

Usage Guidelines4/5

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

The description provides clear context on when to use this tool: for historical price data with specific range and interval options. However, it does not explicitly state when not to use it or mention alternatives among siblings.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Techie03/trade-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server