Skip to main content
Glama

Quote a buy or sell across QX and QSwap

qmax_get_quote
Read-onlyIdempotent

Prices an order and finds the cheapest route across the QX order book and the QSwap pool, splitting the order across both when that is cheaper. Nothing is placed.

Returns an openInQMax link (when the order can be filled) that opens QMax with this order filled in, for the person to review and sign in their own wallet. Also returns the total in QU, the average price, each leg (venue, quantity, price range, fees, price impact), what each single market alone would cost, a plain-English line saying what the routing saved, and warnings. All amounts are QU; quantities are whole units. The quote is a snapshot: prices move, so it can differ a moment later.

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": {
      "side": "<side>",
      "asset": "<asset>",
      "qty": "<qty>"
    },
    "name": "qmax_get_quote"
  }
}

Input Schema

NameRequiredDescriptionDefault
qtyYesHow many units of the asset
sideYesWhether the order buys or sells the asset (a buy spends QU, a sell receives QU)
assetYesAsset symbol, for example CFB or QDOGE (case does not matter). qmax_list_assets lists the tradable symbols.
splitNofalse prices the best single market only
slippage_bpsNoSlippage tolerance in basis points (100 = 1%), applied to the limits in route[].execution

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / side / description
      Added value: +"Whether the order buys or sells the asset (a buy spends QU, a sell receives QU)"
  2. Changed1 schema field changed
    • changedInput schema / properties / asset / description
      Previous value: -"Asset symbol, for example CFB or QDOGE (case does not matter). Use qmax_list_assets to find one."New value: +"Asset symbol, for example CFB or QDOGE (case does not matter). qmax_list_assets lists the tradable symbols."
  3. First observed

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive); the description adds genuinely new context: nothing is executed, the user must review and sign in their own wallet via the returned link, and the quote is a snapshot that can drift. That is real behavioral value beyond the annotations. It stops short of covering failure modes (e.g. when no route can be filled and no link is returned).

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 behavior and the critical "Nothing is placed" disclaimer, then the sign-in-wallet hand-off. The return-value sentence is long and list-like, but since there is no output schema that enumeration earns its place; it could still be trimmed slightly.

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 no output schema, the description carries the return-value burden and does so thoroughly (link, total in QU, average price, per-leg detail, single-market comparison, savings line, warnings). Combined with annotations and full schema coverage this is nearly complete; only error/no-route behavior is unaddressed.

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 the baseline is 3. The description still adds meaning the schema doesn't: all amounts are denominated in QU and quantities are whole units, plus an explanation of what splitting does in routing terms. Slippage and its effect on execution limits are left to the schema.

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 specific verb and resource: prices an order and finds the cheapest route across the QX order book and QSwap pool, with split routing. An agent can tell it is a quoting/routing tool rather than a data-read tool. It does not, however, distinguish itself from the sibling qmax_swap_quote, which sounds like an adjacent quoting tool.

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?

"Nothing is placed" and the openInQMax hand-off imply this is the pre-trade quote step, which is useful implied guidance. But there is no explicit statement of when to use this versus qmax_swap_quote, qmax_build_plan, or qmax_get_order_book, and no exclusion of cases where a single-venue quote is wanted (other than via the split parameter).

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.