v2

OpenAPI 3.0.02026-07-311824171.4 MB
Trading
Matching Engine
Private

Places buy and/or sell orders (quotes) on one or more instruments simultaneously. This method is designed for market makers who need to quote on multiple instruments efficiently.

Requirements:

  • Cancel-on-Disconnect must be enabled (see private/enable_cancel_on_disconnect), otherwise the request will return an error.
  • This endpoint can only be used after approval from the administrators.

Each quote can include both bid and ask sides, or just one side. Quotes are identified by quote_set_id for targeted cancellation. Use the wait_for_response parameter to control whether to wait for all orders to be processed before returning.

Accepted quotes are published to the standard Deribit order book and are visible in the UI and non-Starbase market data feeds.

📖 Related Article: Mass Quotes Specifications

Scope: trade:read_write

Try in API console

get/private/mass_quote

Query parameters

wait_for_responseboolean

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.

detailedboolean
Example:true

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

quote_idstring required
Example:1

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

mmp_groupstring required
Example:default

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.

valid_untilinteger

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 <a href='#public-get_time'>/public/time</a> method to obtain current server time.

instrument_namestring

The name of the instrument.

quote_set_idstring

User-defined label that can be used for targeted cancels using private/cancel_quotes.

List of 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
    }
  }
]

Response

Success response

jsonrpc'2.0' required

The JSON-RPC version (2.0)

idinteger

The id that was sent in the request

Example response

{
  "result": {
    "orders": [
      {
        "order_id": "ETH-100234",
        "instrument_name": "BTC-PERPETUAL",
        "creation_timestamp": 1536569522277,
        "last_update_timestamp": 1536569522277,
        "starbase_last_update_timestamp": 1536569522277000000,
        "block_trade": true,
        "trigger_order_id": "SLIB-370",
        "combo_order_id": "103148386169",
        "starbase_order_id": 103148386170,
        "app_name": "Example Application",
        "mmp_cancelled": true,
        "oto_order_ids": [
          "ETH-100234"
        ],
        "primary_order_id": "ETH-100234"
      }
    ],
    "trades": [
      {
        "instrument_name": "BTC-PERPETUAL",
        "timestamp": 1517329113791,
        "starbase_timestamp": 1536569522277000000,
        "starbase_order_id": 103148386170,
        "block_trade_id": "154",
        "block_trade_leg_count": 3
      }
    ]
  }
}