v1
latestOpenAPI 3.0.32026-07-2613529376.3 KBCollateral Trading
Collateral Stop-Limit Order
The endpoint creates a collateral stop-limit order using collateral balance. The order remains inactive until the market price reaches activation_price, then places a limit order at price. Optionally attach stopLoss and takeProfit prices to create an OTO order that activates after the stop-limit order fills.
<Warning> Rate limit: 10000 requests/10 sec. </Warning> <Accordion title="Error Codes"> - `30` - default validation error code. Also returned when `reduceOnly=true` is combined with `stopLoss` or `takeProfit` - `31` - market validation failed - `32` - amount validation failed - `33` - price validation failed - `36` - clientOrderId validation failed - `10` - insufficient balance to place the order - `111` - resulting position would exceed the market maximum - `112` - pending orders value would exceed the allowed maximum - `113` - position side cannot be changed while open positions or orders exist - `114` - hedge mode position side does not match (sent `BOTH` or omitted `positionSide` in hedge mode, or sent `LONG`/`SHORT` in one-way mode) - `115` - order would open a position in the opposite direction (one-way mode) - `116` - reduce-only validation failed (no position exists or order side matches position direction) </Accordion>post/api/v4/order/collateral/stop-limit
Request body
Example request
{
"market": "BTC_USDT",
"side": "buy",
"amount": "0.001",
"price": "40000",
"activation_price": "40000",
"stopLoss": "30000",
"takeProfit": "50000",
"clientOrderId": "order1987111",
"positionSide": "LONG",
"stp": "no",
"request": "{{request}}",
"nonce": 1594297865000
}Response
Successful response - stop-limit order created
Example response
{
"orderId": 4180284841,
"clientOrderId": "order1987111",
"market": "BTC_USDT",
"side": "buy",
"type": "stop limit",
"timestamp": 1595792396.165973,
"dealMoney": "0",
"dealStock": "0",
"amount": "0.001",
"left": "0.001",
"dealFee": "0",
"price": "40000",
"activation_price": "40000",
"status": "FILLED",
"stp": "no",
"oto": {
"otoId": 29457221,
"stopLoss": "30000",
"takeProfit": "50000"
},
"positionSide": "LONG"
}