post https://api.connex.trade/api/v1/algo/order
Rate Limit: 3 requests per 10 seconds
Place a new algo order, this api is asynchronous. Returning success only means that the request is successful. The final result needs to be confirmed through websocket subscription and order query.
Request
Field name | Type | Necessary | Remarks |
---|---|---|---|
clientOrderId | String | N | Customer defined order ID ,only support letters(a-z) and numbers(0-9) |
algoOrderType | String | Y | Algo order types: TPSL ATTACHED_TPSL has been moved to normal orders endpoint. |
sym | String | Y | Sym(unique identifier:Exchange_Business_Base_Counter. Example: If you want to place a SPOT order for the BTC/USDT trading pair on the Binance exchange, you can use a unique identifier like this: "BINANCE_SPOT_BTC_USDT" ; If you want to place a PERPETUAL order for the BTC/USDT trading pair on the Binance exchange, you can use a unique identifier like this: "BINANCE_PERP_BTC_USDT" ; ) Note that we currently only support the SPOT and PERPETUAL trade of Binance and OKX. |
side | String | N | Side(BUY, SELL) |
limitPrice | String | N | Limit order price(Mandatory for limit order) |
orderQty | String | N | Order quantity(Mandatory, unless spot market buy ) note: trading unit of OKX is the number of contracts/ trading unit of Binance is the number of coin |
positionSide | String | N | Position side, NONE/LONG/SHORT , default NONE . NONE stands for one-way mode. |
reduceOnly | String | N | Reduce position orders only, must "true" or "false" |
TP/SL:only support PERP syms.
Field name | Type | Necessary | Remarks |
---|---|---|---|
conditionType | String | Y | CONDITIONAL / OCO / ENTIRE_CLOSE_POSITION / PARTIAL_CLOSE_POSITION |
conditionalTriggerPrice | String | N | Trigger Price for CONDITIONAL order |
conditionalTriggerType | String | N | Trigger Price Type for CONDITIONAL order. LAST_PRICE / MARK_PRICE |
conditionalPrice | String | N | Limit Price for CONDITIONAL order ;0 Indicates Market Price |
tpTriggerPrice | String | N | Take-profit trigger price. |
tpTriggerType | String | N | Take-profit trigger price type:LAST_PRICE , MARK_PRICE The default is LAST_PRICE |
tpPrice | String | N | Take-profit order price; If the price is 0, take-profit will be executed at the market price. |
slTriggerPrice | String | N | Stop-loss trigger price |
slTriggerType | String | N | Stop-loss trigger price type:LAST_PRICE , MARK_PRICE The default is LAST_PRICE |
slPrice | String | N | Stop-loss order price; If the price is 0, stop-loss will be executed at the market price. |
Response
Field name | Type | Remarks |
---|---|---|
algoOrderId | String | Algo order ID |
clientOrderId | String | Customer defined order ID |