Skip to main content
cURL
curl --request GET \
  --url https://test.deribit.com/api/v2/private/get_margins \
  --header 'Content-Type: application/json' \
  --data '
{
  "jsonrpc": "2.0",
  "id": 7,
  "method": "private/get_margins",
  "params": {
    "instrument_name": "BTC-PERPETUAL",
    "amount": 10000,
    "price": 3725
  }
}
'
{
  "jsonrpc": "2.0",
  "id": 7,
  "result": {
    "sell": 0,
    "min_price": 3684.8,
    "max_price": 3759.24,
    "buy": 0.0219949
  }
}

Query Parameters

instrument_name
string
required

Instrument name Unique instrument identifier

Example:

"BTC-PERPETUAL"

amount
number
required

It represents the requested order size. For perpetual and inverse futures the amount is in USD units. For options and linear futures it is the underlying base currency coin.

price
number
required

Price

Example:

3725

Response

200 - application/json

Success response

jsonrpc
enum<string>
required

The JSON-RPC version (2.0)

Available options:
2.0
result
object
required
id
integer

The id that was sent in the request