place_order
Execute futures trades on Binance by placing market, limit, or conditional orders like stop-loss and take-profit to manage positions.
Instructions
Place a new futures order.
ORDER TYPE GROUPS — choose the right one:
Immediate orders (fill now or queue at price): MARKET: side=BUY, quantity=0.01 LIMIT: side=SELL, quantity=0.01, price=50000, time_in_force=GTC
Conditional orders (wait for stop_price trigger, then execute): Stop-loss full close: side=SELL, type=STOP_MARKET, stop_price=45000, close_position=True Take-profit full close: side=SELL, type=TAKE_PROFIT_MARKET, stop_price=60000, close_position=True Stop-loss partial: side=SELL, type=STOP_MARKET, stop_price=45000, quantity=0.01, reduce_only=True Trailing stop: side=SELL, type=TRAILING_STOP_MARKET, stop_price=45000, quantity=0.01, callback_rate=1.0
IMPORTANT — close_position=True vs quantity+reduce_only: close_position=True → closes the ENTIRE position, no quantity needed, max 1 SL + 1 TP active at a time. reduce_only=True → closes a PARTIAL quantity, multiple allowed simultaneously. Never mix both on the same order.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| symbol | Yes | Trading pair, e.g. 'BTCUSDT' | |
| side | Yes | Order direction | |
| order_type | Yes | Order type. Two distinct groups with different rules: ENTRY/EXIT orders (placed immediately, quantity required): MARKET — executes at current market price LIMIT — executes at `price` or better; requires price + time_in_force CONDITIONAL orders (wait for trigger, routed to Algo API): STOP_MARKET — market exit when price hits stop_price (stop-loss) TAKE_PROFIT_MARKET — market exit when price hits stop_price (take-profit) STOP — limit exit at `price` when stop_price is hit TAKE_PROFIT — limit exit at `price` when stop_price is hit TRAILING_STOP_MARKET — trails price by callback_rate % | |
| quantity | No | Order quantity in base asset. Required for MARKET, LIMIT, STOP, TAKE_PROFIT, TRAILING_STOP_MARKET, and conditional orders without close_position=True. Omit only when using close_position=True (closes the full position). | |
| price | No | Limit fill price. Required for LIMIT, STOP, TAKE_PROFIT. | |
| stop_price | No | Trigger price. Required for all conditional types: STOP, STOP_MARKET, TAKE_PROFIT, TAKE_PROFIT_MARKET, TRAILING_STOP_MARKET. | |
| time_in_force | No | Time in force. Required for LIMIT. Optional for conditional orders (default GTC). | |
| reduce_only | No | If True, order can only reduce an existing position (partial close). Use this with a specific quantity to partially close. Cannot be combined with close_position=True. | |
| close_position | No | If True, closes the ENTIRE position when triggered (Close-All). Only valid with STOP_MARKET or TAKE_PROFIT_MARKET. Do NOT send quantity. Binance allows at most 1 active close_position=True order per type per direction — cancel the existing one first before placing a replacement. | |
| position_side | No | Required in Hedge Mode. Use BOTH for One-way mode. | |
| client_order_id | No | Optional custom order ID (max 36 chars). | |
| callback_rate | No | Trailing stop callback rate in % (0.1–10). Only for TRAILING_STOP_MARKET. |