monaco.api.orders
Source: protos/api/orders.proto
Use OrdersService for authenticated order management.
Notes
- Order creation, cancellation, replacement, and listing require authentication.
- Batch RPCs are the preferred path for multi-order workflows.
- Attach TP/SL through order placement or
PositionsService.AttachPositionTpSl. GetConditionalOrderfetches a single TP/SL order by UUID — the same IDs returned astake_profit_order_idandstop_loss_order_idinCreateOrderResponse.- A trigger and the order it fires into are linked in both directions, and both reads are owner-scoped.
GetConditionalOrderandListConditionalOrderscarrytriggered_order— the close’s current status, filled quantity, average fill price, taker fees, fill time and terminal reason, read from that order at request time — present only oncestateis TRIGGERED and the close can be read, never on a FAILED conditional, and never on theconditional_ordersWebSocket frames.GetOrder/ListOrderscarry the reverse pointerconditional_order_idon a close the engine placed for a trigger; it is absent on client-placed orders, on TWAP children (they carryparent_order_id), and on closes older than the field, which are not backfilled. ListOrdersreturns book orders only (LIMITandMARKET): TWAP parents and conditional (TP/SL) orders are not rows of it under anystatusortrading_modefilter and are not counted intotal; list them withListTwapOrdersandListConditionalOrders. The close a trigger fired into is a book order and is listed as its own row carryingconditional_order_id.ReplaceOrderandBatchReplaceOrdersrefuse to replace the LIMIT leg a TP/SL fired into — an order carryingconditional_order_id— the way a passive TWAP child is refused: a replacement rests under a new order id the conditional does not point at, which would sever the link both ways. The refusal names the conditional order and the original leg stays resting; in a batch the refused item’s original is never cancelled. Cancelling a triggered leg is unchanged.- TWAP parent orders execute a large order as scheduled market child orders across a time window.
CreateTwapOrder,CancelTwapOrder,GetTwapOrder, andListTwapOrdersmanage the parent lifecycle;GetTwapOrderreturns theTwapOrderread model directly. Delegated-agent sessions are rejected for all TWAP RPCs. See TWAP Orders for the execution model. GetTwapOrderTcareturns the post-execution transaction cost analysis report for a terminal TWAP parent (COMPLETEDorCANCELLED). A non-terminal parent isINVALID_ARGUMENT; another user’s parent isNOT_FOUND, indistinguishable from an unknown ID. The six analytics fields are optional and absent when they cannot be computed honestly.

