Skip to main content

Switch Cross/Isolated Margin

Select cross margin mode or isolated margin mode per symbol level

HTTP Request

POST /v5/position/switch-isolated

Request Parameters

ParameterRequiredTypeComments
categorytruestringProduct type
  • UTA2.0: not supported
  • UTA1.0: inverse
  • Classic: linear(USDT Preps), inverse
symboltruestringSymbol name, like BTCUSDT, uppercase only
tradeModetrueinteger0: cross margin. 1: isolated margin
buyLeveragetruestringThe value must be equal to sellLeverage value
sellLeveragetruestringThe value must be equal to buyLeverage value

Response Parameters

None

Request Example

POST /v5/position/switch-isolated HTTP/1.1
Host: api-testnet.bybit.com
X-BAPI-SIGN-TYPE: 2
X-BAPI-SIGN: XXXXX
X-BAPI-API-KEY: XXXXX
X-BAPI-TIMESTAMP: 1675248447965
X-BAPI-RECV-WINDOW: 5000
Content-Type: application/json
Content-Length: 121

{
"category": "linear",
"symbol": "ETHUSDT",
"tradeMode": 1,
"buyLeverage": "10",
"sellLeverage": "10"
}

Response Example

{
"retCode": 0,
"retMsg": "OK",
"result": {},
"retExtInfo": {},
"time": 1675248433635
}