UNPKG

sei-agent-kit

Version:

A package for building AI agents on the SEI blockchain

20 lines 962 B
import { StructuredTool } from "langchain/tools"; import { z } from "zod"; const CitrexCancelOpenOrdersForProductInputSchema = z.object({ productId: z.number().int().positive().describe("The product ID of the orders to be cancelled"), }); export class SeiCitrexCancelOpenOrdersForProductTool extends StructuredTool { seiKit; name = "citrex_cancel_open_orders_for_product"; description = "Cancels all open orders for a specific product on the Citrex Protocol. This is useful for quickly closing all positions for a particular trading pair. Returns a success flag indicating whether the operation was successful."; schema = CitrexCancelOpenOrdersForProductInputSchema; constructor(seiKit) { super(); this.seiKit = seiKit; } async _call(input) { const { productId } = input; return this.seiKit.citrexCancelOpenOrdersForProduct(productId); } } //# sourceMappingURL=cancelOpenOrdersForProduct.js.map