Skip to main content

Time-Weighted Average Price(Twap) New Order(TRADE)

API Description#

Place a new spot TWAP order with Algo service.

HTTP Request#

POST /sapi/v1/algo/spot/newOrderTwap

Request Weight(UID)#


Request Parameters#

symbolSTRINGYESTrading symbol eg. BTCUSDT
sideENUMYESTrading side ( BUY or SELL )
quantityDECIMALYESQuantity of base asset; The notional (quantity * last price(base asset)) must be more than the equivalent of 1,000 USDT and less than the equivalent of 100,000 USDT
durationLONGYESDuration for TWAP orders in seconds. [300, 86400]
clientAlgoIdSTRINGNOA unique id among Algo orders (length should be 32 characters), If it is not sent, we will give default value
limitPriceDECIMALNOLimit price of the order; If it is not sent, will place order by market price by default
stpModeENUMNOThe allowed enums is dependent on what is configured on the symbol. The possible supported values are EXPIRE_TAKER, EXPIRE_MAKER, EXPIRE_BOTH, NONE
  • Total Algo open orders max allowed: 10 orders.

Response Example#

{    "clientAlgoId": "65ce1630101a480b85915d7e11fd5078",    "success": true,    "code": 0,    "msg": "OK"}