Summary
Deribit offers a mass quote functionality. This functionality allows users to place many orders (with some restrictions, hereafter called quotes) in a single request, and removes the need to have an order ID before amending or cancelling. The main strength of the mass quote is its ability to skip almost all risk checks that currently slow down order entry.
In order to skip the risk checks without increasing risk to the platform another mechanism is introduced: MMP groups. Each mass quote message will have an associated MMP group that makes sure enough initial margin (IM) is reserved. Each MMP group will reserve some IM at all times, based on the MMP quantity limit configured by the user. To make sure this IM is enough to cover all possible trades, only one quote per side per instrument is allowed, and each quote must have an amount lower than the MMP quantity limit. MMP groups are configurable in a similar way as the current MMP system. Clients can create many (~16) of these groups per subaccount.
The reason we do not use the existing “global“ MMP system but these groups is to allow users to have multiple quotes on the same side of the same instrument and to allow users to have different MMP settings for instrument groups with different risk profiles. Quotes have a separate rate limit and are fully integrated into the current event system.
Notice
Enabling Market Maker Protection (MMP) does not automatically enable the Mass Quote feature. These are separate systems and must be requested and activated independently. If you require Mass Quote functionality, please contact Deribit support to request access explicitly.
Details
Instrument Availability
-
Mass quotes are available for perpetuals, dated futures, options, option combos, and future spreads.
-
Mass quotes are disabled for options on Standard Margin (SM) accounts, as we do not margin long options on SM.
-
Mass quotes are also disabled for spot orders since we do not margin spot.
Impact on MMP
-
Creating an MMP group is possible through the existing endpoint (
private/set_mmp_config
). This group is separate from the current MMP system and can have different settings. It will reserve IM at all times, even without positions or open orders in the account. -
Removing an MMP group can be achieved by setting its interval to 0, which will release the reserved IM.
-
A mass quote request must include an MMP group name, linking all quotes in the request with the designated MMP group. Multiple MMP groups are allowed, enabling the client to have different MMP settings and triggers for distinct product groups.
-
Only one quote per side per instrument per MMP group is permitted. A new quote in an MMP group will override any existing quote. For n layers in the order book, at least n MMP groups are required to ensure bypassing most risk checks and margin mutations, thus reducing latency.
-
The amount per quote must be below the MMP
quantity_limit
of its respective MMP group. -
All quotes are implicitly tagged with
mmp=true
. The endpointprivate/reset_mmp
allows clients to reset specific groups. -
We enforce
delta_limit < quantity_limit
to ensure proper margining. -
If an MMP group is modified, all resting quotes exceeding the new
quantity_limit
are cancelled. -
MMP group names must be unique across the account.
-
There is a limit for the
quantity_limit
: 500 BTC and 5000 ETH (subject to change).
Impact on Sessions
-
The connection must have
Cancel-on-Disconnect
enabled. Without this, all endpoints permitting the placement of new quotes will return an error. -
Routine use of
Cancel-on-Disconnect
for pulling orders is discouraged.
Priority in LOB
-
Normal priority rules apply, except when a quote is amended without changing the price, amount, or
QuoteSetID
. In such cases, priority is lost to prevent spamming of the same quote repeatedly. -
Amending only the
QuoteSetID
can be done without a loss of priority. -
Each side of the quote has its own priority, such that one side can be amended without affecting the priority of the other side.
New Endpoints
-
For WebSocket:
private/mass_quote
. For FIX:<i>
. This can also function as a cancel by amending with an amount of 0. -
Quotes can be retrieved using
private/get_open_orders
. All quotes are tagged withquote=true
. -
For WebSocket:
private/cancel_quotes
. For FIX:<Z>
. This endpoint allows clients to cancel all quotes or filter by currency pair/kind/instrument/QuoteSetID
/delta range. The delta range is based on Deribit’s internal delta calculation and works for options and option combos, but not for futures or future spreads. -
After a mass cancel, all quotes will be optionally rejected for 1 second.
-
The mass quoting and cancelling endpoints have separate rate limits from the existing order rate limits.
Existing Endpoints
-
The existing order endpoints, such as
New Order Single <D>
orprivate/buy
, do not work on quotes to keep the new pathway to the book as segregated as possible.
Mass Quote Request Composition
-
Only quotes for the same index (currency pair) are allowed in one message. If quotes from different indices are submitted, all quotes will be rejected.
-
Quotes can be grouped using a
QuoteSetID
. -
The total amount of quotes in a single mass quote is 100, meaning 100 bids and 100 asks. If this amount is exceeded, all quotes in the request will fail.
-
Quotes are processed from head to tail, so ordering quotes from highest to lowest priority can be beneficial.
-
Repeated sending of identical quotes is discouraged.
-
An MMP group must be provided; if a non-existent MMP group is passed, the request will error.
FIX Logic
-
Responses to Mass Quote
<i>
messages will be Quote Acknowledgement<b>
messages, depending on theQuoteResponseLevel
. -
Quote Status Request
<a>
and Quote Cancel<Z>
will be responded to with a Quote Status Report<AI>
. -
Amendments or executions of quotes will be pushed as Execution Report
<8>
messages.
WebSocket Logic
-
We will respond to a
private/mass_quote
request with a single response, either giving a count of errors or listing each error mapped to the offending quote using the instrument name and side. This depends on an optional boolean in the request. -
Quotes are versioned by
QuoteID
, allowing clients to determine which mass quote message an executed quote originated from. -
The
QuoteID
is a user-defined string, and we recommend keeping it unique and incrementing so both the client and customer support can easily link trades to specific mass quote requests. -
The
mmp.triggers.{index_name}
stream now has a global version,mmp.triggers.any
, which will broadcast any MMP trigger across all currency pairs. -
The MMP endpoints
private/reset_mmp
,private/get_mmp_config
, andprivate/set_mmp_config
now have an optional parametermmp_group
to allow getting/setting/resetting specific MMP groups. Ifmmp_group
is not provided, the global MMP settings are used. The global settings can only be used for regular orders.
Subaccounts
-
All mass quote logic operates at the subaccount level. Margin for MMP is taken from subaccounts by default, which is also the level at which mass quotes function.
Rate Limits
-
There is a separate rate limit for mass quoting and mass cancelling quotes.
-
A "guaranteed rate limit" is always available, regardless of the number of quotes in mass quotes.
-
A "maximum rate limit" can be used if the number of quotes stays below a specific threshold. This encourages clients to batch quotes into single messages while accommodating instrument types where large batches are not feasible, such as dated futures, future spreads, or ITM options.
Accessibility
-
Access will be restricted in case of abuse, including:
-
Spamming identical quotes.
-
Spamming cancellations.
-
Attempting to place quotes above the MMP
quantity_limit
. -
Exceeding the rate limit.
-
Triggering MMP frequently.
-
Quote Logic
-
Quotes behave like simple limit orders with a time-in-force of "good-til-cancel".
-
Quotes cannot be (partly) hidden.
-
Quotes cannot be priced in anything other than the standard pricing unit of the instrument.
-
If both the bid and ask are modified and both move upwards, the ask is modified first. If both move downwards, the bid is modified first. This helps avoid crossing the client spread when possible. If the price of one quote crosses another, both are rejected/cancelled.
-
Quotes may fail independently. For example, if the bid price is outside the bandwidth, a valid ask will still enter the book.
-
If no amount is passed, amendments are done in a volume-safe way. If there is no current quote, an error will be returned.
-
If an amendment errors, the resting quote on that side (or both sides, if both sides error) will be cancelled.
-
Priority is not lost when amending to a smaller size or when only amending the
QuoteSetID
. -
Quotes interact with reduce-only orders in the same way as regular orders. Reduce-only orders should be avoided unless necessary due to latency.
-
Quotes can be post-only, either when rejecting or amending, similar to how it works for orders.
UI
-
Quotes are shown in the UI with an extra tag, "Quote".
-
All quotes can be cancelled using the "Cancel all" button.
API Documentation
Documentation for production is available at docs.deribit.com.