Skip to main content
Glama

Cancel an unpaid EMC order

cancel_order
Destructive

Cancel a still-unpaid buy_emc order by its token, expiring it now and freeing its slot ahead of the TTL. Use this only before you pay; once a payment is in flight or confirmed it is too late and this errors. A payment sent after cancellation matches nothing and is NOT refunded. To only inspect an order without changing it, use get_order_status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tokenYesopaque order handle returned by buy_emc; pass it back unchanged

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
statusYes
emc_txidNo
order_idYeshuman-quotable order number (DB id)
emc_amountYes
expires_atYes
amount_usdtYes
deposit_addressYes
destination_emc_addressYes

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already indicate destructiveHint=true. Description adds that it errors if payment is in flight/confirmed and that payments after cancellation are not refunded. No contradiction.

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, front-loaded with the core action and effect. Every sentence is essential and free of fluff.

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 simple one-parameter input and the presence of annotations and output schema, the description fully covers usage context, prerequisites, consequences, and error scenarios.

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?

Only one parameter (token) with 100% schema coverage. The description does not add new detail beyond what the schema provides (opaque handle, from buy_emc). Baseline 3 is appropriate.

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?

Clearly states it cancels an unpaid buy_emc order by token, expiring it and freeing its slot. Distinguishes from sibling get_order_status for inspection.

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?

Explicitly says use only before payment, warns against using after payment is in flight/confirmed, and notes that post-cancellation payments are not refunded. Provides alternative tool get_order_status for inspection.

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.7/5.0
Disambiguation5/5

Each tool has a distinct purpose: creating an order, cancelling it, checking its status, and fetching configuration. No overlap in functionality.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern in snake_case (e.g., buy_emc, cancel_order), making them predictable.

Tool Count5/5

With 4 tools, the set is well-scoped for the specific domain of EMC-USDT swaps, covering all necessary actions without bloat.

Completeness5/5

The tools cover the full lifecycle: get configuration, create an order, check status, and cancel before payment. No obvious missing operations for this narrow domain.

Resources