placeBatchOrders
Execute multiple cryptocurrency trading orders simultaneously on Aster Finance to manage portfolio positions efficiently and save time on manual order placement.
Instructions
Place multiple orders.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| batchOrders | Yes |
Implementation Reference
- src/index.ts:627-632 (handler)Executes the placeBatchOrders tool by validating the presence of batchOrders, stringifying it for the API, and making a signed POST request to the Aster futures batchOrders endpoint.case 'placeBatchOrders': if (!args || !args.batchOrders) { throw new McpError(ErrorCode.InvalidParams, 'batchOrders is required.'); } const batchOrdersStr = JSON.stringify(args.batchOrders); return makeRequest('POST', '/fapi/v1/batchOrders', { ...args, batchOrders: batchOrdersStr }, true);
- src/index.ts:258-281 (schema)Defines the input schema and registers the placeBatchOrders tool in the listTools response, requiring a batchOrders array of order objects with symbol, side, type, and quantity.{ name: 'placeBatchOrders', description: 'Place multiple orders.', inputSchema: { type: 'object', properties: { batchOrders: { type: 'array', items: { type: 'object', properties: { symbol: { type: 'string' }, side: { type: 'string', enum: ['BUY', 'SELL'] }, type: { type: 'string' }, quantity: { type: 'number' }, price: { type: 'number' }, }, required: ['symbol', 'side', 'type', 'quantity'], }, }, }, required: ['batchOrders'], }, },