Skip to main content
Glama

getTokenOHLCV

Read-onlyIdempotent

Get historical USD OHLCV candles for one token over a time range, returned as a time-series array. The price and volume are computed across every pool the token trades in on the network (a volume-weighted price, and volume summed across those pools), not a single pair. Runs on the caller's own Dev, Pro or Enterprise API key, set as the Authorization header on the connection to this server; without one it returns DP401_API_KEY_REQUIRED and sends nothing upstream, and a free key gets 403. In either case fall back to getPoolOHLCV on the token's main pool, found with getTokenPools sorted by volume. Use for 'price history of this token' or 'USD chart for this token'; for a single pair's candles use getPoolOHLCV, and for the current price use getTokenDetails. Params: network (required); token_address (required); start (required; easiest as a relative offset from now such as '-24h', so you need not know today's date; also Unix seconds, RFC3339 or yyyy-mm-dd); end (optional, same formats); interval one of '1m','5m','10m','15m','30m','1h','6h','12h','24h' (default '24h'); limit (default 10, max 1000 candles). Dev plan history is limited to the last 30 days. There is no inversed parameter on this endpoint.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
endNoOPTIONAL: End time, same formats as start (e.g. '-1h')
limitNoOPTIONAL: Number of data points to retrieve (default: 10, max: 1000)
startYesREQUIRED: Start time. A relative offset from now is simplest and needs no knowledge of today's date: '-24h' (last 24 hours), '-7d', '-90m' (units s, m, h, d). Also accepts RFC3339 (e.g. '2024-01-01T00:00:00Z'), Unix epoch seconds and YYYY-MM-DD (treated as 00:00:00 UTC).
networkYesREQUIRED: Network ID from getNetworks (e.g., 'ethereum', 'solana')
intervalNoOPTIONAL: Interval granularity (default: '24h')24h
rationaleYesREQUIRED. 1-2 sentence rationale for this call (e.g. "User asked for X; calling Y to fetch Z"). Logged for MCP improvement, never shown to end users. No PII or secrets. See the server `instructions` field for the full convention and worked examples.
token_addressYesREQUIRED: Token contract address

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
ohlcvYesUSD candles for the token across all its pools, ordered by time_open ascending.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only declare the read-only/idempotent safety profile; the description adds substantial context beyond that: keys must run on the caller's Dev/Pro/Enterprise key via Authorization header, no key yields DP401_API_KEY_REQUIRED without sending anything upstream, a free key yields 403, and Dev-plan history caps at 30 days. It also discloses the aggregation semantics (volume-weighted price, summed volume).

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 the core purpose and aggregation caveat before alternatives, then auth behavior, then params. It is dense and long, but nearly every sentence carries operational weight; only the param enumeration slightly duplicates the schema rather than adding new 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?

An output schema exists, so return-value explanation is unnecessary, and the description still conveys the shape (a time-series array). It covers auth requirements, error paths, plan limits, aggregation semantics, and sibling routing, leaving no gap an agent needs to call it correctly.

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 most parameter detail is already documented. The description still adds value by foregrounding the relative-offset convention as the 'easiest' form and by noting 'there is no inversed parameter on this endpoint', a disambiguation not in the schema, though it largely restates the interval/limit/default facts.

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?

States a specific verb+resource (get historical USD OHLCV candles for one token) and immediately qualifies the scope: aggregated across every pool the token trades in, volume-weighted, not a single pair. It explicitly distinguishes itself from getPoolOHLCV and getTokenDetails, so an agent can route without opening either 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?

Gives explicit use cases ('price history of this token', 'USD chart for this token'), names two alternatives with the condition that selects each (getPoolOHLCV for a single pair, getTokenDetails for current price), and even describes the fallback path when auth fails. Nothing is left to inference.

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.

Resources