Skip to main content

Overview

Market Maker Protection (MMP) helps reduce exposure risk by automatically pausing quoting activity when certain limits are reached. MMP monitors trading activity and automatically cancels all MMP-tagged orders when exposure limits are breached, then freezes quoting for a configured duration.
For comprehensive MMP configuration details, see:

MMP in Starbase Binary API

The Starbase Binary API provides the following MMP capabilities:
  1. MMP-tagged Orders – Orders can be tagged with MMP flags to participate in MMP protection
  2. Mass Quoting - Quotes placed by Mass Quoting have MMP enforced
  3. MMP Trigger Events – Receive real-time notifications when MMP limits are breached via MassQuoteMmpTriggered and OrdersMmpTriggered events
  4. Resetting MMP – Manually resetting MMP limits after a freeze to resume quoting

MMP-Tagged Orders

Orders placed via the Starbase Binary API can be tagged with MMP flags to participate in Market Maker Protection. When MMP limits are breached, all orders within the same underlying with the MMP flag enabled are automatically canceled. For details on how to enable MMP for individual orders, refer to the order entry documentation:

Quotes and MMP

MMP is required for quotes. For quotes, MMP groups can be defined per underlying. MMP groups are entirely independent from each other, allowing you to configure different risk limits for different underlyings. For more information on quotes:
MMP Trigger Messaging: Cancels resulting from MMP triggers might not be sent in the same message as the fill that caused the MMP trigger. The fact that MMP is triggered will be indicated on the order/quote fill.

Resetting MMP

If your MMP protection has been triggered and quoting is frozen for a given index, you can resume quoting either automatically after the configured freeze time or manually via the Starbase Binary API.
If the configured frozen_time has expired, the system will automatically reset MMP and quoting resumes for that index
The minimum fozen_time is 1 second. Unfreezing is not possible until 1 second after an MMP trigger. This is to allow the risk engine time to process the sequence of trades that caused the trigger.

Manual Reset Methods

You can manually reset MMP using any of the following methods:
  1. JSON-RPC API: Call private/reset_mmp to reset MMP for a specific index or MMP group
  2. Reset Flags in Order Messages: Use reset flags in order entry messages to unfreeze MMP while placing or amending orders:
    • NewOrderRequest (Field 10, flag 5: resetMmp) - Unfreeze orders MMP group when placing a new order
    • AmendOrderRequest (Field 7, flag 5: resetMmp) - Unfreeze orders MMP group when amending an existing order
    • MassQuoteRequest (Fields 14/15, flag 3: resetMMP) - If an MMP freeze is active, this flag will remove the freeze before processing the rest of the message. Keep in mind there is a mandatory 1 second freeze that can’t be overruled
Mandatory Minimum Freeze Period: There is a mandatory minimum 1 second freeze period that cannot be overruled by any reset method (including reset flags). This minimum freeze period allows Deribit to properly risk manage. When using reset flags in order messages, the MMP freeze is removed before processing the order/quote, but you must wait at least 1 second after the MMP trigger before quoting can resume.

Reset Behavior

  • If frozen_time is set to 0 (automatic reset disabled), you must use one of the manual reset methods to re-enable quoting
  • You can perform a manual reset during the frozen period if you want to resume quoting early (after the minimum 1 second period)
  • After reset, the previous MMP configuration remains unchanged (the limits, interval, etc. stay in effect)

Monitoring MMP

You can monitor MMP status and configuration using multiple methods:

JSON-RPC API

  • private/get_mmp_config - Returns all currently active MMP parameters for the selected index
  • private/get_mmp_status - Returns the live MMP state for the index, including whether MMP is triggered and remaining frozen time

WebSocket Notifications

For real-time MMP trigger notifications, subscribe to the user.mmp_trigger.{index_name} channel via WebSocket.

Binary API Trigger Events

When MMP limits are breached, the Starbase Binary API sends unsolicited events to notify you of the trigger and provide details about canceled orders.
  • MassQuoteMmpTriggered (320): Event generated when a mass quote Market Maker Protection limit is triggered. This event is sent for MMP groups used in mass quotes.
  • OrdersMmpTriggered (322): Event generated when an orders Market Maker Protection limit is triggered. This event is sent for standard orders (not mass quotes) when MMP limits are breached at the index level.
  • MassQuoteMmpUnfrozen (324): Event generated when a mass quote MMP group is unfrozen, either via a reset request or because the frozenUntil timer elapsed.
  • OrdersMmpUnfrozen (326): Event generated when an orders MMP group is unfrozen, either via a reset request or because the frozenUntil timer elapsed.
Multiple Messages: If not all canceled order IDs fit in one message, multiple messages may be sent. Check the flags field to determine if more messages are coming (0 = isLastMessage).

MMP Configuration

MMP configuration is managed through the JSON-RPC API. To configure MMP settings, use the private/set_mmp_config method. This method allows you to set MMP parameters including quantity limits, delta limits, vega limits, interval, frozen time, and maximum quote quantity (MQQ).