Skip to main content
Glama
questflowai

Aster Finance MCP Server

by questflowai

cancelBatchOrders

Cancel multiple cryptocurrency trading orders simultaneously on Aster Finance Futures by specifying order IDs or client order IDs for a given trading symbol.

Instructions

Cancel multiple orders.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
orderIdListNo
origClientOrderIdListNo
symbolYes

Implementation Reference

  • The core handler for the 'cancelBatchOrders' tool. Validates input parameters, stringifies array parameters (orderIdList or origClientOrderIdList) as required by the API, and delegates to the shared makeRequest helper to perform a signed DELETE request to the '/fapi/v1/batchOrders' endpoint.
    case 'cancelBatchOrders':
        if (!args || (!args.orderIdList && !args.origClientOrderIdList)) {
            throw new McpError(ErrorCode.InvalidParams, 'Either orderIdList or origClientOrderIdList is required.');
        }
        const params = { ...args };
        if (params.orderIdList) {
            params.orderIdList = JSON.stringify(params.orderIdList);
        }
        if (params.origClientOrderIdList) {
            params.origClientOrderIdList = JSON.stringify(params.origClientOrderIdList);
        }
        return makeRequest('DELETE', '/fapi/v1/batchOrders', params, true);
  • Input schema definition for the 'cancelBatchOrders' tool, specifying parameters like symbol (required), orderIdList (array of numbers), and origClientOrderIdList (array of strings). Used for validation in MCP tool calls.
    inputSchema: {
      type: 'object',
      properties: {
        symbol: { type: 'string' },
        orderIdList: { type: 'array', items: { type: 'number' } },
        origClientOrderIdList: { type: 'array', items: { type: 'string' } },
      },
      required: ['symbol'],
    },
  • src/index.ts:333-345 (registration)
    Registration of the 'cancelBatchOrders' tool in the ListTools response, including its name, description, and input schema. This makes the tool discoverable by MCP clients.
    {
      name: 'cancelBatchOrders',
      description: 'Cancel multiple orders.',
      inputSchema: {
        type: 'object',
        properties: {
          symbol: { type: 'string' },
          orderIdList: { type: 'array', items: { type: 'number' } },
          origClientOrderIdList: { type: 'array', items: { type: 'string' } },
        },
        required: ['symbol'],
      },
    },
Behavior2/5

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

No annotations are provided, so the description carries full burden. 'Cancel multiple orders' implies a destructive write operation, but it doesn't disclose critical behavioral traits: whether it requires authentication, rate limits, idempotency, confirmation mechanisms, or what happens on partial failure. For a batch mutation tool, this is a significant gap.

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 description is a single, efficient sentence with zero waste. It's front-loaded with the core action, though it lacks detail due to under-specification rather than conciseness.

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

Completeness2/5

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

Given the complexity (batch mutation tool), lack of annotations, 0% schema coverage, and no output schema, the description is incomplete. It fails to explain parameters, behavioral expectations, or output, leaving the agent poorly equipped to use this tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It mentions 'multiple orders' but doesn't explain the three parameters (orderIdList, origClientOrderIdList, symbol) or their relationships. The agent must guess how to specify which orders to cancel, making this inadequate for a tool with undocumented parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Cancel multiple orders' states the action (cancel) and resource (orders), but it's vague about scope and mechanism. It doesn't distinguish from sibling tools like cancelOrder (single order) or cancelAllOpenOrders (all open orders), leaving ambiguity about whether this cancels specific orders, all orders for a symbol, or something else.

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?

No guidance is provided on when to use this tool versus alternatives like cancelOrder or cancelAllOpenOrders. The description doesn't mention prerequisites, constraints, or typical use cases, leaving the agent to infer usage from context alone.

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/questflowai/aster-mcp-server'

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