Get stock price history
market_get_stock_priceFetch current price and historical price data for stocks, indices, or exchange rates. Provides price, 52-week range, and a sampled historical table.
Instructions
Get the current price and price history for a ticker (any exchange: US tickers as-is, others with a Yahoo suffix like 'SAP.DE', 'MC.PA', 'SHOP.TO', '7203.T'), an index ('^GSPC', '^MXX') or an exchange rate ('EURUSD=X', 'MXN=X' for USD/MXN). Returns current price, 52-week range, return over the range, max drawdown, and a sampled price table (split/dividend-adjusted closes). Source: Yahoo Finance's public chart endpoint (unofficial; may occasionally be unavailable).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| range | No | History range (default 1y). | 1y |
| symbol | Yes | Ticker, e.g. 'AAPL', 'BRK-B', 'SAP.DE'. | |
| max_points | No | Rows in the price table (default 24, evenly sampled). | |
| response_format | No | Output format: 'markdown' (readable, default) or 'json' (structured). | markdown |