Close Position
Close position
Close an open collateral trading position at market price via the WhiteBIT V4 API.
POST
Close Position
Authorizations
The public WhiteBIT API key.
Base64-encoded JSON request body.
HMAC-SHA512 signature of the payload, hex-encoded. Computed as hex(HMAC-SHA512(payload, api_secret)).
Body
application/json
Unique identifier of the position to close. Obtain from the open positions endpoint.
Example:
123
Market of the position to close. Example: BTC_USDT
Example:
"BTC_USDT"
Example:
"{{request}}"
Example:
"{{nonce}}"
Defines the position direction when hedge mode is enabled. See positionSide
Available options:
LONG, SHORT, BOTH Example:
"LONG"
Response
Position closed