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)
3000
Request Parameters
Name | Type | Mandatory | Description |
---|---|---|---|
symbol | STRING | YES | Trading symbol eg. BTCUSDT |
side | ENUM | YES | Trading side ( BUY or SELL ) |
quantity | DECIMAL | YES | Quantity 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 |
duration | LONG | YES | Duration for TWAP orders in seconds. [300, 86400] |
clientAlgoId | STRING | NO | A unique id among Algo orders (length should be 32 characters), If it is not sent, we will give default value |
limitPrice | DECIMAL | NO | Limit price of the order; If it is not sent, will place order by market price by default |
stpMode | ENUM | NO | The allowed enums is dependent on what is configured on the symbol. The possible supported values are EXPIRE_TAKER , EXPIRE_MAKER , EXPIRE_BOTH , NONE |
recvWindow | LONG | NO | |
timestamp | LONG | YES |
- Total Algo open orders max allowed:
20
orders.
Response Example
{
"clientAlgoId": "65ce1630101a480b85915d7e11fd5078",
"success": true,
"code": 0,
"msg": "OK"
}