Skip to main content

Close Positions

Frequency limit: 10 times/1s (user ID)

Interface for followers to close positions. Can close positions based on order ID, trading pair, direction, position mode, and margin

HTTP Request

  • POST /api/v2/copy/mix-follower/close-positions
Request Example
curl -X POST "https://api.cointr.com/api/v2/copy/mix-follower/close-positions" \
-H "ACCESS-KEY:your apiKey" \
-H "ACCESS-SIGN:*******" \
-H "ACCESS-PASSPHRASE:*****" \
-H "ACCESS-TIMESTAMP:1659076670000" \
-H "locale:en-US" \
-H "Content-Type: application/json" \
-d '{"symbol": "BTCUSDT","productType": "usdt-futures","trackingNo": "1"}'

Request Parameters

ParameterTypeRequiredDescription
productTypeStringYesProduct type
USDT-FUTURES USDT professional futures
COIN-FUTURES Mixed futures
USDC-FUTURES USDC professional futures
trackingNoStringNoTracking numbers of buying orders grouped by trading pair
(If you pass the trackingNo and ensure that the symbol, marginCoin, marginMode, and holdSide are not empty, you need to ensure that the trackingNo corresponds to them.)
symbolStringNoTrading pair
marginCoinStringNomargin coin
marginModeStringNoPosition mode
isolated: isolated margin
cross: cross margin
holdSideStringNoPosition direction
1. In the buying and selling (one-way position) mode: you don’t have to fill it in, if you fill it in, it will be ignored.
2. In the opening and closing position (hedge mode): This parameter must be filled in.
long: long position in hedging mode
short: short position in hedging mode
Response example
{
"code": "00000",
"data": {
"orderIdList": [
"123",
"321"
]
},
"msg": "success",
"requestTime": 1627293504612
}

Response parameters

ParameterTypeDescription
orderIdListList<String>Order ID