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'], }, },

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