BitMart futures supports three categories of advanced conditional orders beyond simple limit and market orders. This page covers all three and their management methods. All methods require authentication (SIGNED).Documentation Index
Fetch the complete documentation index at: https://mintlify.com/tiagosiebler/bitmart-api/llms.txt
Use this file to discover all available pages before exploring further.
Setup
Plan Orders
Plan orders are trigger-based conditional orders. When the market price reaches thetrigger_price, the exchange submits a limit or market order at the executive_price on your behalf.
submitFuturesPlanOrder(params)
Submits a new plan (trigger) order.
Signature
Contract symbol (e.g.
BTCUSDT).Order side:
1— buy_open_long2— buy_close_short3— sell_close_long4— sell_open_short
The market price level that activates this order.
The price at which the triggered order executes (required for
limit type; omit for market).Trigger direction:
1 = price rises to trigger, 2 = price falls to trigger.Which price to compare against:
1 = last price, 2 = mark price.Order quantity in contracts.
Leverage multiplier (e.g.
"10").Margin mode:
cross or isolated.Execution type:
limit (default), market, take_profit, or stop_loss.Time-in-force:
1=GTC, 2=FOK, 3=IOC, 4=Post Only.Plan category:
1 = normal plan, 2 = position TP/SL plan.Optional preset take-profit price to attach when the plan order triggers.
Optional preset stop-loss price to attach when the plan order triggers.
cancelFuturesPlanOrder(params)
Cancels a pending plan order by order ID or client order ID.
Signature
Contract symbol.
Exchange plan order ID to cancel.
Client order ID to cancel.
updateFuturesPlanOrder(params)
Modifies the trigger price and/or execution price of an existing pending plan order.
Signature
Contract symbol.
Plan order ID to modify.
New trigger price.
New execution price (for limit orders).
Price reference:
1 = last price, 2 = mark price.Order type:
limit or market.updateFuturesPresetPlanOrder(params)
Modifies the preset take-profit and/or stop-loss prices attached to an existing plan order (set at submission time).
Signature
Plan order ID.
Contract symbol.
New take-profit price.
New stop-loss price.
TP price type:
1 = last price, 2 = mark price.SL price type:
1 = last price, 2 = mark price.getFuturesAccountPlanOrders(params?)
Returns all currently active plan orders.
Signature
Filter by contract symbol.
Filter by execution type:
limit or market.Maximum results to return.
Filter by plan category:
plan (normal) or profit_loss (TP/SL plan).Take-Profit / Stop-Loss Orders
TP/SL orders are position-level conditional orders that execute against an existing open position when the trigger price is reached. They differ from plan orders in that they are attached to a position rather than opening a new one.side for TP/SL orders is limited to 2 (buy_close_short — close a short) or 3 (sell_close_long — close a long), since TP/SL orders always close existing positions.submitFuturesTPSLOrder(params)
Submits a take-profit or stop-loss order against an open position.
Signature
Contract symbol (e.g.
BTCUSDT).Order type:
take_profit or stop_loss.Close side:
2 (buy_close_short) or 3 (sell_close_long).The market price at which this order activates.
The price at which the order executes once triggered (for limit execution).
Reference price for trigger:
1 = last price, 2 = mark price.Quantity to close in contracts. Omit to close the entire position.
Plan category:
1 = position TP/SL, 2 = preset TP/SL on plan order.Optional client-defined ID.
Execution category:
limit or market.updateFuturesTPSLOrder(params)
Modifies the trigger price and/or execution price of an existing TP/SL order.
Signature
Contract symbol.
TP/SL order ID to modify.
Client order ID to modify.
New trigger price.
New execution price.
Reference price:
1 = last price, 2 = mark price.Plan category:
1 or 2.Execution type:
limit or market.Trailing Stop Orders
Trail orders follow the market at a fixed percentage distance (callback_rate). As price moves in your favour, the stop price trails automatically. If price reverses by the callback_rate, the order triggers and closes your position.
submitFuturesTrailOrder(params)
Submits a trailing stop order.
Signature
Contract symbol (e.g.
BTCUSDT).Order side (1–4, same values as standard orders).
Leverage multiplier.
Margin mode:
cross or isolated.Order quantity in contracts.
Price at which trailing starts. The trailing stop does not activate until this price is reached.
Trailing callback percentage (e.g.
"1.5" for 1.5%). The order triggers when price reverses by this percentage from its peak/trough.Reference price for activation:
1 = last price, 2 = mark price.Trail orders combine an activation price with a callback rate. The stop does not activate until
activation_price is reached, then trails by callback_rate. This avoids premature triggering on entry volatility.cancelFuturesTrailOrder(params)
Cancels an active trailing stop order.
Signature
Contract symbol.
Trail order ID to cancel.