Skip to main content
Glama

HelmSwap

Prepare an unsigned order

prepare_order
Read-only

Prepare an unsigned server-run order for the user's own wallet: limit, take_profit, stop_loss, trailing_stop, tp_sl (one cancels the other) or dca. Uses a live quote. Returns humanSummary (read it to the user), the typed data the user's wallet signs, any approvals, the request bodies to send after signing, expiresAt (prepare again after it), and reviewUrl: a link that opens the order on HelmSwap's own review screen, for users who cannot sign typed data in chat. Nothing is signed or submitted here. Base and Solana only. Multi-leg exit plans are only on the website. Percent inputs are versus the live price: targetPct above, stopPct below, floorPct = max slippage past the stop.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "owner": "<owner>",
      "tokenIn": "<tokenIn>",
      "tokenOut": "<tokenOut>",
      "amountIn": "<amountIn>",
      "type": "<type>"
    },
    "name": "prepare_order"
  }
}

Input Schema

NameRequiredDescriptionDefault
daysNoExpiry in days (1–30, default 7).
typeYes
chainNo'base' or 'solana'.
ownerYesThe user's wallet address (address only, never a key).
stopPctNo
tokenInYesToken to sell (ERC-20 address on Base, mint on Solana).
amountInYesInteger amount of tokenIn in its smallest unit.
dcaHoursNo
floorPctNo
tokenOutYesToken to receive.
trailPctNo
dcaSlicesNo
targetPctNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=false, and openWorldHint=true. The description adds genuinely useful behavior beyond that: nothing is signed or submitted, the output includes humanSummary/typed data/approvals/request bodies/expiresAt/reviewUrl, and expiry means re-preparation is required. The non-idempotency implied by a live quote and expiry is consistent with the annotations rather than contradictory.

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?

Information is front-loaded (what it does, what it returns, what it does not do) and every clause carries real content such as expiry semantics, chain restrictions, and percent definitions. The prose is dense and runs long in places, but there is little outright waste.

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?

For a 13-parameter mutation-preparation tool with no output schema, the description compensates well by describing the returned fields explicitly (humanSummary, typed data, approvals, request bodies, expiresAt, reviewUrl) and the sign-then-submit flow. The remaining gap is the undocumented trailing-stop and DCA parameters, which an agent would have to guess at.

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 46%, so the description must carry weight, and it does for the percent family (targetPct above price, stopPct below, floorPct as max slippage past the stop) plus the type enum meaning. However trailPct, dcaHours, and dcaSlices remain undocumented anywhere, leaving three parameters semantically opaque.

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 names a specific verb and resource ('Prepare an unsigned server-run order') and then enumerates the exact order types supported (limit, take_profit, stop_loss, trailing_stop, tp_sl, dca), which lets an agent distinguish this from sibling swap-building tools without opening the schema. It also states hard scope limits ('Base and Solana only', 'Multi-leg exit plans are only on the website').

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?

Usage context is clear: prepare here, then the user signs, then the returned request bodies are sent, and the order must be prepared again after expiresAt. The reviewUrl escape hatch is explained for users who cannot sign typed data. It stops short of explicitly naming an alternative tool (e.g., build_swap) for straightforward swaps, so sibling selection is still implied rather than stated.

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.