client.complex_orders.create() or the top-level shortcut client.create_complex_order() to submit a complex order to POST /v1/complex-orders.
Method
POST /v1/complex-orders
Parameters
"ICEBERG" | "PEG" | "STOP" | "TP_SL" | "SMART_ROUTE"
required
The complex order type that determines execution behaviour.
string
required
The subaccount from which to manage child orders.
integer
Venue-specific instrument ID. Required when using
DIRECT routing.integer
Cross-venue asset ID. Required when using
BEST_PRICE or SPLIT routing."BUY" | "SELL"
Direction of child orders. Required for most complex order types.
"YES" | "NO"
Binary outcome leg. Required for binary markets where the instrument tracks a specific resolution outcome.
string
Total quantity as a decimal string. For ICEBERG, this is the full hidden quantity.
string
Reference price as a decimal string. Interpretation varies by type: limit price for STOP child orders, initial peg price for PEG, and so on.
object
Type-specific configuration parameters. The fields accepted here depend on
type.object
Routing configuration object.
string
Idempotency key for this complex order. Unlike simple orders (which use
client_order_id), complex orders use this dedicated field. Retrying with the same key and body is safe; retrying with the same key and a different body raises ConflictError.Examples
ICEBERG order
An ICEBERG order hides the full quantity and exposes only aslice_qty at a time. As each slice fills, a new child order is automatically placed until the total quantity is exhausted.
STOP order
A STOP order watches the market and submits a child order when the price crossestrigger_price.
TP_SL order
A TP_SL order places a take-profit and stop-loss simultaneously, managing both legs until one triggers and the other is cancelled.Managing complex orders
Useclient.complex_orders to retrieve, list, and cancel complex orders:
Idempotency
Complex orders use the
idempotency_key field — not client_order_id. Sending the same idempotency_key with the same body is safe to retry and returns the original response. Sending the same key with a different body raises ConflictError with error code idempotency_conflict.