Skip to main content
Glama
Typus-Lab

typus-perp-mcp

Official
by Typus-Lab

cancel_order

Cancel a pending trading order by providing its order ID and market index. Retrieve order details with get_orders to identify the correct identifiers.

Instructions

Cancel a pending trading order. Requires PRIVATE_KEY in .env.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
orderIdYesThe order ID to cancel. Use get_orders to find order IDs.
marketIndexYesThe market index the order belongs to. Use get_orders to find the marketIndex for each order.
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It discloses a prerequisite: 'Requires PRIVATE_KEY in .env.' and the 'pending' constraint. However, it does not disclose what happens on successful cancellation (e.g., irreversible, no confirmation), potential error conditions, or whether the order is removed from the book immediately. This is some context, but not rich behavioral detail.

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?

The entire description is two short sentences, immediately stating the purpose and the key prerequisite. It is front-loaded and free of unnecessary detail, making it easy for an agent to process quickly. Every word earns its place.

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

Completeness3/5

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

The tool is simple with two well-documented parameters, but there is no output schema and the description does not mention what the tool returns (e.g., success status, transaction hash, or error details). It also does not clarify behavior for invalid or already-cancelled orders. Given the lack of output schema, the description should have provided at least a hint about the return value or expected outcome, but it is otherwise adequate for the tool's simplicity.

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?

The input schema already provides 100% coverage with descriptions for both parameters, each directing the user to 'get_orders' for finding valid values. The tool description does not add additional parameter semantics beyond this. Since the schema already explains the parameters well, the baseline of 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?

The description clearly states the tool's action with a specific verb and resource: 'Cancel a pending trading order.' This distinguishes it from other trading tools like create_order or get_orders, though it does not explicitly name any sibling alternatives. The phrase 'pending trading order' adds useful scoping.

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

Usage Guidelines2/5

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

The description provides no explicit guidance on when to use this tool versus alternatives. It implicitly suggests that only pending orders can be cancelled, but it does not explain when cancellation is appropriate or mention any related tools (e.g., get_orders for finding order IDs is only in the schema, not the description). There is no 'when not to use' or comparison with other tools.

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/Typus-Lab/typus-perp-mcp'

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