list_dca_orders
Retrieve and filter DCA (Dollar-Cost Averaging) orders by status and limit on Armor Crypto MCP. Access detailed order responses for managing crypto trading strategies.
Instructions
List all DCA orders.
Returns a list of DCAOrderResponse.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| list_dca_order_requests | Yes |
Implementation Reference
- armor_crypto_mcp/armor_mcp.py:434-447 (handler)MCP tool handler for 'list_dca_orders'. Registers the tool and handles execution by proxying to ArmorClient.list_dca_orders after login check.@mcp.tool() async def list_dca_orders(list_dca_order_requests: ListDCAOrderRequest) -> ListDCAOrderResponseContainer: """ List all DCA orders. Returns a list of DCAOrderResponse. """ if not armor_client: return [{"error": "Not logged in"}] try: result: ListDCAOrderResponseContainer = await armor_client.list_dca_orders(list_dca_order_requests) return result except Exception as e: return [{"error": str(e)}]
- armor_crypto_mcp/armor_mcp.py:434-434 (registration)Registration of the 'list_dca_orders' tool using @mcp.tool() decorator.@mcp.tool()
- Input schema for list_dca_orders: ListDCAOrderRequest defining optional status filter and limit.class ListDCAOrderRequest(BaseModel): status: Optional[Literal["COMPLETED", "OPEN", "CANCELLED"]] = Field(description="status of the DCA orders, if specified filters the results.") limit: Optional[int] = Field(default=30, description="number of mostrecent results to return")
- Output schema container: ListDCAOrderResponseContainer wrapping list of DCAOrderResponse.class ListDCAOrderResponseContainer(BaseModel): list_dca_order_responses: List[DCAOrderResponse]
- Core helper function in ArmorClient that makes the API call to list DCA orders.async def list_dca_orders(self, data: ListDCAOrderRequest) -> ListDCAOrderResponseContainer: """List all DCA orders.""" payload = data.model_dump(exclude_none=True) return await self._api_call("POST", f"transactions/dca-order/", payload)