Submit a market, limit, or stop order
Submits an order for processing. Returns a command_id you can use to track status.
Order types:
market— executes immediately at best available pricelimit— executes when price reaches your level or better (requiresprice)stop— triggers a market order when price reaches stop level (requiresprice)
Bracket orders: optionally attach take_profit and/or stop_loss prices. These create child limit/stop orders that auto-cancel each other (OCO) when one fills.
Validation: checks account ownership, trading status, lockout, max contracts rule, and tick size before accepting.
Requires x-idempotency-key header to prevent duplicate submissions.
{
"accepted": true,
"command_id": "2f95ccde-3f33-4fa0-a84d-1a9bdf8575ff",
"status": "queued"
}{
"code": "ERROR_CODE",
"data": null,
"error": "Error message describing what went wrong",
"success": false
}{
"code": "UNAUTHORIZED",
"data": null,
"error": "Invalid or missing JWT token",
"success": false
}{
"code": "LOCKOUT_ACTIVE",
"data": null,
"error": "Account is locked out until 2026-03-12T16:00:00Z (mode: timed, 45 minutes remaining)",
"success": false
}{
"code": "NOT_FOUND",
"data": null,
"error": "Account not found",
"success": false
}{
"code": "RATE_LIMITED",
"data": null,
"error": "Rate limit exceeded for order submissions. Max 10 requests per second per account. Retry after 100 ms.",
"rate_limit": {
"limit": 10,
"remaining": 0,
"reset": 1711800125,
"retry_after": 0.1
},
"success": false
}Authorizations
Body
Order submission request
Submit a market, limit, or stop order for a specific trading account.
Examples
Market Order (immediate execution):
{
"account_id": "550e8400-e29b-41d4-a716-446655440000",
"contract": "ESH6",
"side": "buy",
"quantity": 2
}
Limit Order (execute at specified price or better):
{
"account_id": "550e8400-e29b-41d4-a716-446655440000",
"contract": "ESH6",
"side": "sell",
"quantity": 1,
"order_type": "limit",
"price": 6050.25
}
Stop Order (trigger market order when price reached):
{
"account_id": "550e8400-e29b-41d4-a716-446655440000",
"contract": "NQH6",
"side": "sell",
"quantity": 1,
"order_type": "stop",
"price": 21000.00
}
How this order's TP/SL relate to the position's existing bracket when SCALING IN (adding to an open position). Optional:
"position"— consolidate into ONE stop / ONE target for the whole position. The existing position bracket grows to cover the added contracts at its own price; this order's levels are dropped for the legs that already exist."ladder"— legs given as absolute prices (take_profit/stop_loss) become their own TP/SL legs alongside the position bracket (partial-exit ladder), even at the same price.- omitted — legs given as absolute prices consolidate when they are at the same price as the position bracket and become their own legs when the price differs.
A leg given as tick offsets (take_profit_ticks / stop_loss_ticks)
always consolidates into the position bracket on a scale-in, whatever
bracket_intent says. To keep separate exits per entry, send absolute
prices with "ladder".
Has no effect when the order opens a fresh position or carries no TP/SL.
"position"
Only reduce the open position (optional, default false). The order is rejected when there is nothing on the opposite side to close, and is trimmed or cancelled at execution if the position has shrunk since — it can never open or flip a position. Cannot carry TP/SL.
false
Stop loss price for bracket orders (optional). Creates a stop order to close position at this price. For buy orders: SL should be below entry price. For sell orders: SL should be above entry price.
Partial fills follow the same lifecycle as take_profit: armed on
the first fill for the filled contracts, grown with later fills,
kept when the entry remainder is cancelled.
6000
Take profit price for bracket orders (optional). Creates a limit order to close position at this price. For buy orders: TP should be above entry price. For sell orders: TP should be below entry price.
Partial fills: a resting entry that fills in several executions arms its TP on the FIRST fill, sized to the contracts filled so far, and the TP grows automatically as the remainder fills. Cancelling the unfilled remainder keeps the armed TP for the open contracts. If the TP/SL closes the position while part of the entry is still unfilled, the remainder is cancelled too (the bracket strategy is complete).
6100
Take-profit distance in ticks from the entry (optional). The engine
prices the bracket off the ACTUAL entry — the fill price for market
orders, the limit price for resting limits — so a stale client-side
market snapshot can never plant a bracket on the wrong side of the
real market. On a resting stop the planned level is provisional
(measured off the trigger) and is re-priced from the stop's actual
fill when it triggers, so slippage does not shorten the distance.
Ignored when take_profit is provided; an absolute level, or a
planned level later moved with modify, stays where it was placed.
x >= 0120
Limit orders only (optional, default "gtc"):
"gtc"— good till cancelled: rests until filled or cancelled."ioc"— immediate or cancel: fills what the book offers at the limit on arrival; the rest is cancelled. Rejected if nothing fills."fok"— fill or kill: fills the whole amount on arrival or is rejected with nothing executed."gtx"— post only: rejected if it would execute on arrival, so it always rests and pays the maker fee on perpetuals.
"gtc"
{
"accepted": true,
"command_id": "2f95ccde-3f33-4fa0-a84d-1a9bdf8575ff",
"status": "queued"
}{
"code": "ERROR_CODE",
"data": null,
"error": "Error message describing what went wrong",
"success": false
}{
"code": "UNAUTHORIZED",
"data": null,
"error": "Invalid or missing JWT token",
"success": false
}{
"code": "LOCKOUT_ACTIVE",
"data": null,
"error": "Account is locked out until 2026-03-12T16:00:00Z (mode: timed, 45 minutes remaining)",
"success": false
}{
"code": "NOT_FOUND",
"data": null,
"error": "Account not found",
"success": false
}{
"code": "RATE_LIMITED",
"data": null,
"error": "Rate limit exceeded for order submissions. Max 10 requests per second per account. Retry after 100 ms.",
"rate_limit": {
"limit": 10,
"remaining": 0,
"reset": 1711800125,
"retry_after": 0.1
},
"success": false
}