Skip to main content
Glama

pre_trade_check

Read-only

Check a crypto perpetual futures order against your risk rules before placing it; get pass/fail metrics and GO, CAUTION, or WAIT. Read-only, places no orders.

Instructions

Returns a pre-trade check of a crypto perpetual futures order against your own rules: each passes or fails with its numbers, then GO, CAUTION or WAIT. Adds isolated liquidation distance, whether it hits before your stop, fees, accuracy needed to break even over your hold, funding by venue (cross-venue) and the regime. Read-only: places no orders.

Input Schema

NameRequiredDescriptionDefault
coinYesAsset symbol, e.g. BTC, ETH, SOL.
sideYesDirection of the order you intend to place: long or short.
rulesNoYour rules, each key optional. A rule of yours that fails returns WAIT.
sizeUsdYesOrder notional in USD, e.g. 10000.
stopPctNoStop-loss distance from entry in percent, e.g. 2.
leverageNoIsolated leverage you will use, e.g. 10. Enables the liquidation checks.
equityUsdNoAccount equity in USD. Enables the percent-of-equity rules.
exchangesNoOnly compare these venues (default: every supported venue).
holdHoursNoExpected holding time in hours (default 8); sets the funding cost window.
orderTypeNomarket (taker entry) or limit (maker entry). Default market.market
targetPctNoTarget distance from entry in percent, e.g. 4.
timeframeNoMarket-regime timeframe: 1h, 4h or 1d (default 4h).4h

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.33.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, and the description usefully reinforces this with 'Read-only: places no orders' so the agent knows nothing is submitted. It also adds substantive behavior beyond the annotations: the return shape (per-rule numbers then a GO/CAUTION/WAIT verdict) and the extra analytics bundled in (liquidation distance vs. stop, fees, break-even accuracy, cross-venue funding, regime). It stops short of latency, data freshness, or what happens when no rules are supplied.

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?

Three sentences, front-loaded with the primary output contract (per-rule pass/fail then verdict) before the supplementary analytics and the safety note. Every clause carries information, though the middle sentence is a dense comma-separated list that is harder to scan than the rest.

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

Completeness4/5

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

With 12 parameters, a nested rules object, and no output schema, the description does the heavy lifting of explaining what comes back (per-rule results plus a verdict) and what supplementary analysis is included. Gaps remain around the no-rules case and the fact that optional inputs gate entire check families, but the per-parameter schema descriptions cover those mechanics.

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 every one of the 12 parameters, including the nested rules object, is already documented in structured form. The description only gestures at parameter meaning indirectly ('funding by venue (cross-venue)' maps to exchanges, 'over your hold' maps to holdHours) and adds no syntax, defaults, or interaction detail beyond the schema — baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a precise verb and resource: it returns a pre-trade check of a hypothetical crypto perpetual futures order against the caller's own rules, with a per-rule pass/fail and a final GO/CAUTION/WAIT verdict. The 'against your own rules' framing implicitly separates it from the signal-fetching siblings (get_trade_call, get_trade_signal), but no sibling is named, so differentiation is inferable rather than explicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by 'pre-trade check' and 'places no orders' — it is a gate you run before submitting an order elsewhere — but the description never states when to prefer it over scan_trade_calls or get_trade_call, nor that certain checks only activate when optional fields like leverage or equityUsd are supplied. That prerequisite guidance lives only in the schema, leaving usage to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.