Integration
Adjusting Leverage (Isolated Per-Market)
Overview
Ekiden supports isolated leverage settings per market. This allows users to control risk independently for each trading pair. Adjusting leverage changes how much margin is allocated to your open position in a given market. Increasing leverage frees up margin but increases liquidation risk, while lowering leverage adds margin and decreases risk.
Endpoint
POST /api/v1/leverage
Adjust the leverage multiplier for a specific market. This endpoint applies only to the specified market and cancels any open orders associated with it.
Headers
Request Parameters
Parameter | Type | Description | Required |
---|---|---|---|
market | string | Market symbol (e.g. BTC-PERP) | Yes |
leverage | integer | New leverage (e.g. 10 for 10x) | Yes |
subAccount | string | Optional subaccount identifier | No |
Example Request
Example cURL
Response
Error Example
SDK Examples
TypeScript
Python
Notes
- Leverage is isolated per market
- Min = 1x, Max = varies by market
- Open orders are cancelled when leverage is changed
- Changing leverage affects margin ratio and liquidation price
- Cannot increase leverage if margin requirements would be violated
For current leverage settings or account info, use GET /api/v1/account
or the relevant SDK method.