Skip to main content
Glama

Get Backtest Result

get_backtest_result
Read-onlyIdempotent

Fetches a submitted backtest by id. By default (waitForCompletion: true) polls internally until it finishes, so one call returns one final answer — no need to poll from the caller's side. Only aggregate metrics are returned here, no trade-by-trade detail — call get_backtest_trades for that (paginated, sortable). Fetching many results from the same submit_backtest_batch call? Use get_backtest_batch_results instead.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoThe id returned by submit_backtest.
pollTimeoutMsNoDefaults to 120000 (2 minutes).
backtestApiKeyNoYour EmidLabs backtest API key. Not needed if this connector was added with a static 'x-api-key' header.
backtestBaseUrlNoDefaults to the public production API.
waitForCompletionNoIf true (default), polls internally until the backtest finishes or pollTimeoutMs elapses.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNo
resultNo
statusNo
runtimeMsNoHow long the analyser actually took to run this backtest, in milliseconds — pure compute time, not counting queue/messaging latency. Null until Status is "Completed".
errorMessageNo
recentAvgPnlRNoAverage pnlR of the most recent RecentTradeCount closed trades. This is the recency signal for a rolling ranking — weighted alongside expectancyR, not a replacement for it.
unitsConsumedNoThe actual execution-unit cost of this backtest, matching what's debited from the account's plan balance (CandlesProcessed normalized by the account's candles-per-unit rate). Null until Status is "Completed".
recentOutcomesNo"Win"/"Loss" per recent trade, chronological — oldest first, so the LAST element is the most recent trade. Lets a caller see whether recent trades were genuinely a streak (e.g. all "Loss") versus alternating, which RecentAvgPnlR alone can't distinguish.
candlesProcessedNoNumber of candles the analyser processed for this backtest. Null until Status is "Completed". This is raw volume, not the plan's billing unit — see UnitsConsumed for that.
recentTradeCountNoNumber of trades the recency fields below are based on (up to 5, fewer if the backtest has fewer trades). Null until Status is "Completed".

TDQS

A4.7/5.0
Behavior5/5

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

Discloses important behavior beyond annotations: internal polling with waitForCompletion, the single-final-answer contract, and the limitation to aggregate metrics only. These details meaningfully shape an agent's expectations about latency and output scope, complementing the readOnlyHint and idempotentHint annotations.

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?

Three sentences with no filler. The core purpose is front-loaded, followed by the most important behavioral nuance, then targeted sibling routing. Every sentence earns its place.

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?

Given the tool's moderate complexity, a complete input schema, an output schema, and strong annotations, the description covers all essential context: what it does, how polling behaves, what is omitted from results, and which sibling tools handle those omissions. Nothing critical is missing.

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

Parameters3/5

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

Schema description coverage is 100%, so the description adds limited new parameter-level meaning. It does reinforce the id and waitForCompletion semantics, but most parameter explanation is already supplied by the schema, so no significant compensation is needed or provided.

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 action ('Fetches a submitted backtest by id') on a clear resource. It also explicitly distinguishes itself from get_backtest_trades and get_backtest_batch_results by naming what the tool does not return and which sibling covers that need.

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?

Provides explicit guidance on when to use this tool versus alternatives: use get_backtest_trades for trade-by-trade detail and get_backtest_batch_results when fetching many results from a batch. It also clarifies that the caller does not need to poll because the tool polls internally by default.

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.

TDQS

A4.6/5.0
Disambiguation5/5

Each tool targets a distinct resource/action: single backtests, batch backtests, trades, confirmation sources, signals, and asset discovery. The batch getter is explicitly differentiated from the single-result getter, and confirmation sources are clearly separated from tradable backtests.

Naming Consistency5/5

Tool names follow a clear verb_noun pattern: submit_backtest, submit_backtest_batch, get_backtest_result, get_backtest_trades, get_confirmation_source, list_available_assets. Modifiers like batch, trades, and signals are consistent and make each tool's role predictable.

Tool Count5/5

Nine tools is well-scoped for a backtesting server: three submission endpoints, four result-fetching endpoints, signal retrieval, and asset discovery. There is no apparent redundancy or tool bloat.

Completeness5/5

The surface covers the full backtest lifecycle: submitting single and batch backtests, retrieving aggregate results, drilling into trades, creating and reading confirmation sources, and discovering available assets. No critical operation appears missing for the stated domain.

Resources