Skip to content
Market History

MCP server

Market History runs a remote MCP server at https://getmarkethistory.com/mcp (Streamable HTTP). An AI agent connected to it can look up markets and symbols and pull bars on your account. It is the same API underneath: every tool call is billed exactly like the matching /query/v1/ request, against the same balance, under the same limits.

Add https://getmarkethistory.com/mcp to your client. The first time it connects, a browser window opens: sign in with Google or GitHub (a new account is created on the spot), check the app name, and press Allow. No key to copy. Disconnect an app any time from the dashboard (Keys tab, Connected apps).

Claude (claude.ai and Claude Desktop): Settings → Connectors → Add custom connector, paste the URL, then Connect.

Claude Code

Terminal window
claude mcp add --transport http market-history https://getmarkethistory.com/mcp

then run /mcp in Claude Code and pick market-history to sign in.

Cursor and other clients that take a JSON config (.cursor/mcp.json):

{
"mcpServers": {
"market-history": { "url": "https://getmarkethistory.com/mcp" }
}
}

For a client without browser sign-in, or a headless agent, create a key on the dashboard and send it as a header:

Terminal window
claude mcp add --transport http market-history https://getmarkethistory.com/mcp \
--header "Authorization: Bearer $MARKET_HISTORY_KEY"
{
"mcpServers": {
"market-history": {
"url": "https://getmarkethistory.com/mcp",
"headers": { "Authorization": "Bearer mh_live_..." }
}
}
}

A client that only speaks stdio can bridge with npx mcp-remote https://getmarkethistory.com/mcp (it handles the sign-in too), or add --header "Authorization: Bearer mh_live_...".

Tool What it returns Cost
get_coverage Markets, what each holds, timeframes, first and last date Free
search_symbols Tickers in one market containing a substring Free
get_bars OHLCV bars of one symbol, CSV, up to 2,000 rows a call Bars returned, rounded up to 100
get_funding Funding rate events of one perpetual, CSV Rows returned, rounded up to 100
get_corporate_actions Splits, dividends, symbol changes and mergers, CSV Free

Each billed result ends with bars_charged (the same number as the API’s X-Bars-Charged) and next_cursor: pass it back as cursor to fetch the next page. Free monthly bars pay for 1h bars only; other timeframes and funding rates spend bought bars, and a call that your balance cannot pay for is refused with the API’s own message and a top-up link (/buy?bars=…) for the agent to hand you: open it, pay, and tell the agent to retry.

The free tools still count toward the per-account request limits.