Skip to main content
Glama

get_klines_history

Retrieve historical kline data beyond 500 candles by paging backwards, returning up to 5000 candles in oldest-first order for backtesting.

Instructions

Fetch MORE than 500 candles by paging backwards through history. Returns a flat oldest-first list. Use for backtests/long lookbacks; capped at 5000 candles per call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
totalYes
symbolYes
intervalYes
end_time_msNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose key behaviors: it pages backwards, returns an oldest-first flat list, and is capped at 5000 candles. These cover pagination, ordering, and limits. It doesn't mention error handling or rate limits, but these are less critical for a read operation.

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 two sentences with no fluff. The core action and key differentiator are front-loaded, and the use case and limit are added succinctly. Every sentence adds value.

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

Completeness2/5

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

While the output schema exists and covers returns, the description omits essential usage details: how to set end_time_ms for paging backwards, how total interacts with paging, and what happens if total exceeds 5000. For a tool designed for long lookbacks, this information is critical for correct invocation.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate. It implies total is the number of candles ('Fetch MORE than 500 candles') but does not explain symbol, interval, or the crucial end_time_ms parameter used for pagination. This is a significant gap that leaves the agent guessing about parameter values.

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 fetches more than 500 candles by paging backwards, which is a specific verb and resource. It also distinguishes itself from the sibling get_klines by implying a higher limit and historical pagination, so an agent can tell them apart without opening schemas.

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?

It explicitly says 'Use for backtests/long lookbacks', giving a clear context for when to choose this tool. It also notes a 5000 candle cap, implying that ordinary short lookbacks might use get_klines, though it doesn't explicitly name the alternative. This is clear enough for an agent.

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/alejandrorodm/MCP-Pionex'

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