Skip to main content
Glama

Cancel order (agent wallet)

hl_cancel_order
DestructiveIdempotent

Cancel a resting order on Hyperliquid with your local agent wallet by providing coin and order ID. Runs as dry-run by default; set confirm=true and dryRun=false to execute.

Instructions

Cancel a resting order by coin + order id via your local agent wallet. Dry-run by default; set confirm=true AND dryRun=false to submit. Analytics/execution helper, not investment advice.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
oidYesOrder id (from hl_get_open_orders).
coinYesPerp coin symbol of the order.
dryRunNo
confirmNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeYes
actionYes
reasonNo
responseNo
agentAddressNo
builderAttachedNo
Behavior4/5

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

Adds behavioral context beyond annotations by explaining the dry-run default and submission requirements. Annotations already indicate destructiveHint=true and idempotentHint=true, and the description aligns with these without contradicting. It also clarifies the local wallet scope.

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?

Extremely concise: two sentences front-loaded with the primary action, followed by critical usage instructions and a disclaimer. Every sentence adds value without redundancy.

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?

Given the presence of output schema and annotations, the description covers the essential behavioral aspects (dry-run, submission, local wallet). It does not mention failure handling or permission requirements, but these are likely covered by output schema or implied by context.

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?

The description explains the interplay between dryRun and confirm, which is not fully detailed in the schema (only 50% schema coverage). The schema descriptions for oid and coin are sufficient, but the tool description compensates for missing parameter semantics on dryRun and confirm.

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 clearly states the action (cancel) and resource (resting order) with specific identifiers (coin + order id) and scope (local agent wallet). It distinguishes from siblings like hl_place_order and hl_close_position by focusing on cancellation of resting orders.

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?

Provides explicit guidance on dry-run default and the required combination of confirm=true and dryRun=false to submit, which is essential for correct use. However, it does not compare alternatives or specify when not to use this tool relative to siblings.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/johnsmithxy1mmm-sys/HyperliquidMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server