Skip to main content
cURL
curl --request GET \
  --url https://test.deribit.com/api/v2/private/mass_quote \
  --header 'Content-Type: application/json' \
  --data '
{
  "jsonrpc": "2.0",
  "id": 7859,
  "method": "private/mass_quote",
  "params": {
    "detailed": true,
    "quote_id": "1",
    "mmp_group": "default",
    "quotes": [
      {
        "instrument_name": "BTC-PERPETUAL",
        "quote_set_id": "futures",
        "ask": {
          "price": 43800,
          "amount": 10
        },
        "bid": {
          "price": 43700,
          "amount": 10
        }
      },
      {
        "instrument_name": "BTC-22DEC23-41600-C",
        "quote_set_id": "options",
        "ask": {
          "price": 0.05,
          "amount": 1
        },
        "bid": {
          "price": 0.04,
          "amount": 1
        }
      }
    ]
  }
}
'
{
  "jsonrpc": "2.0",
  "id": 7859,
  "result": {
    "errors": [
      {
        "instrument_name": "BTC-PERPETUAL",
        "side": "bid",
        "error": {
          "message": "price_too_high 43666.4288",
          "code": 10007
        }
      }
    ],
    "orders": [
      {
        "is_liquidation": false,
        "reduce_only": false,
        "risk_reducing": false,
        "last_update_timestamp": 1703162550180,
        "creation_timestamp": 1703162478689,
        "filled_amount": 0,
        "average_price": 0,
        "order_type": "limit",
        "order_state": "open",
        "quote": true,
        "quote_set_id": "options",
        "quote_id": "1",
        "post_only": false,
        "replaced": false,
        "mmp_group": "default",
        "web": false,
        "mmp": true,
        "api": false,
        "instrument_name": "BTC-22DEC23-41600-C",
        "order_id": "6653852",
        "max_show": 1,
        "time_in_force": "good_til_cancelled",
        "price": 0.04,
        "direction": "buy",
        "amount": 1,
        "label": ""
      },
      {
        "is_liquidation": false,
        "reduce_only": false,
        "risk_reducing": false,
        "last_update_timestamp": 1703162550180,
        "creation_timestamp": 1703162478689,
        "filled_amount": 0,
        "average_price": 0,
        "order_type": "limit",
        "order_state": "open",
        "quote": true,
        "quote_set_id": "options",
        "quote_id": "1",
        "post_only": false,
        "replaced": false,
        "mmp_group": "default",
        "web": false,
        "mmp": true,
        "api": false,
        "instrument_name": "BTC-22DEC23-41600-C",
        "order_id": "6653853",
        "max_show": 1,
        "time_in_force": "good_til_cancelled",
        "price": 0.05,
        "direction": "sell",
        "amount": 1,
        "label": ""
      },
      {
        "is_liquidation": false,
        "reduce_only": false,
        "risk_reducing": false,
        "last_update_timestamp": 1703162550180,
        "creation_timestamp": 1703162478689,
        "filled_amount": 0,
        "average_price": 0,
        "order_type": "limit",
        "order_state": "open",
        "quote": true,
        "quote_set_id": "futures",
        "quote_id": "1",
        "post_only": false,
        "replaced": false,
        "mmp_group": "default",
        "web": false,
        "mmp": true,
        "api": false,
        "instrument_name": "BTC-PERPETUAL",
        "order_id": "6653855",
        "max_show": 10,
        "time_in_force": "good_til_cancelled",
        "price": 43800,
        "direction": "sell",
        "amount": 10,
        "label": ""
      }
    ],
    "trades": []
  }
}

Query Parameters

wait_for_response
boolean

If false, the response is sent immediately after the risk check. If true, the response is sent after the orders all go through the matching engine. Default - true.

detailed
boolean

Flag to receive a list of all order changes and a list of errors, or to only receive a list of errors. Default - false.

Example:

true

quote_id
string
required

Identifier of a mass quote message. Can be used to match trades to requests. We recommend using an incrementing counter.

Example:

"1"

mmp_group
string
required

Name of the MMP group. An MMP group has to be used and only one quote can exist per instrument per side per MMP group.

Example:

"default"

valid_until
integer

Timestamp, when provided server will start processing request in Matching Engine only before given timestamp, in other cases timed_out error will be responded. Remember that the given timestamp should be consistent with the server's time, use /public/time method to obtain current server time.

quotes
string
required

List of quotes. JSON string containing array of objects

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