How does Zero Hash Update their FIX Market Data Feed?
The Zero Hash CLOB uses the Market By Order (MBO) approach which allows traders and systems to see the open orders at different price levels in the market. The MBO message is used to send incremental updates to the order book. It provides information about new orders, order modifications, and order cancellations.
Why MBO ?
MBO is a stateful order based Market data feed, it provides the ability to view individual queue position, full depth of book and the size of individual orders at each price level.
Market by Price (MBP) restricts updates to a maximum of 10 price levels and consolidates all the quantity into a single update for each price level, which includes total quantity and number of orders. Individual queue position and order sizes cannot be determined with a high degree of accuracy.
How Market By Order (MBO) book works?
When connecting to the CLOB Market Data Gateway, we must send a Market Data Request 35=V
. Our initial message back will be a snapshot of the Market Data, MsgType 35=W
. All orders in the order book will be sorted based on price/time priority. The position in queue of an order can be tracked by use of tag <273>
MDEntryTime.
Tag <268> NoMDEntries indicates how many open orders there are in the market. Each order in the market will have the following fields in the market snapshot message.
-
269 MDEntryType
-
0 = BID
-
1 = OFFER
-
-
270 MDEntryPx
-
Price of the order.
-
-
271 MDEntrySize
-
Quantity of the order.
-
-
272 MDEntryDate
-
Date of the order.
-
-
273 MDEntryTime
-
Time of order entry.
-
-
59 TimeInForce
-
0 = DAY
-
1 = GOOD_TILL_CANCEL
-
3 = IMMEDIATE_OR_CANCEL
-
6 = GOOD_TILL_DATE
-
-
37 OrderID
-
Unique identifier for Order.
-
-
278 MDEntryID
-
Market Data Entry identifier
-
-
40 OrdType
-
2 = LIMIT
-
3 = STOP
-
4 = STOP_LIMIT
-
K = MARKET_WITH_LEFT_OVER_AS_LIMIT
-
How is order updates handled with a MBO schema in the Market Data Feed?
For incremental refresh messages in the Market Data feed on the Zero Hash CLOB, we will send a series of MDEntry messages that represent an individual orders actions. There can be multiple order entries per price level and the incremental messages will provide updates of orders that are New, Updated or deleted.
Market Update messages will be sent in 35=X
messages. To receive incremental update message on the market data gateway, clients will need to send their SubscriptionRequestType as Snapshot & Updates.
-
|263=1|
The initial message is a Snapshot of the Market 35=W
, followed by incremental updates of the market activity
-
<35 = W>
(Initial Snapshot)8=FIXT.1.1|9=1596|35=W|34=2|49=ZERO|52=20230830-21:55:08.165519757|56=C-LPBD-3|22=8|48=BTC/USD|55=BTC/USD|167=FXSPOT|262=2f86194cd13911eca862cedcff009123|1151=BTC|268=12|269=0|270=29748.20|271=0.09284077|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CHK1SFCFX|278=1EW5CHK1SFCFX|40=2|269=0|270=29748.20|271=0.01000000|272=20230830|273=21:54:00.842849199|59=6|126=20230830-22:10:36.714000000|37=1F1KJ21XSBR05|278=1F1KJ21XSBR05|40=2|269=0|270=29748.20|271=0.01000000|272=20230830|273=21:54:00.842849199|59=6|126=20230830-22:10:39.481000000|37=1F1KJ1H9C2808|278=1F1KJ1H9C2808|40=2|269=0|270=29730.33|271=0.20988663|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CGN025M09|278=1EW5CGN025M09|40=2|269=0|270=29715.44|271=0.31482995|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CG5JRV009|278=1EW5CG5JRV009|40=2|269=0|270=29707.75|271=0.00020000|272=20230830|273=21:54:00.842849199|59=1|37=1F0MCCGSHZG01|278=1F0MCCGSHZG01|40=2|269=0|270=29707.75|271=0.00020000|272=20230830|273=21:54:00.842849199|59=1|37=1F0MCCGSHZG02|278=1F0MCCGSHZG02|40=2|269=0|270=29697.57|271=0.41977326|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CGN025M0B|278=1EW5CGN025M0B|40=2|269=1|270=29807.75|271=0.07274331|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CGN025M08|278=1EW5CGN025M08|40=2|269=1|270=29825.62|271=0.20988663|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CH4RSWC08|278=1EW5CH4RSWC08|40=2|269=1|270=29840.51|271=0.31482995|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CGN025M0A|278=1EW5CGN025M0A|40=2|269=1|270=29858.38|271=0.41977326|272=20230830|273=21:54:00.842849199|59=1|37=1EW5CH4RSWC09|278=1EW5CH4RSWC09|40=2|10=015|
-
<35 = X>
(Order Added)8=FIXT.1.1|9=304|35=X|34=3|49=ZERO|52=20230830-21:55:36.159922156|56=C-LPBD-3|262=2f86194cd13911eca862cedcff009123|268=1|279=0|269=0|278=1F1KJ2FK1HC07|55=BTC/USD|48=BTC/USD|22=8|167=FXSPOT|1151=BTC|270=29748.20|271=0.01000000|272=20230830|273=21:55:36.133065599|59=6|126=20230830-22:12:15.436000000|37=1F1KJ2FK1HC07|40=2|10=042|
-
<35 = X>
(Order Added at same price and quantity)8=FIXT.1.1|9=304|35=X|34=4|49=ZERO|52=20230830-21:55:37.613240773|56=C-LPBD-3|262=2f86194cd13911eca862cedcff009123|268=1|279=0|269=0|278=1F1KJ1H9C2809|55=BTC/USD|48=BTC/USD|22=8|167=FXSPOT|1151=BTC|270=29748.20|271=0.01000000|272=20230830|273=21:55:37.603684164|59=6|126=20230830-22:12:17.022000000|37=1F1KJ1H9C2809|40=2|10=224|
-
<35 = X>
(Order Canceled)8=FIXT.1.1|9=305|35=X|34=11|49=ZERO|52=20230830-22:02:05.737179657|56=C-LPBD-3|262=2f86194cd13911eca862cedcff009123|268=1|279=2|269=0|278=1F1KJ21XSBR05|55=BTC/USD|48=BTC/USD|22=8|167=FXSPOT|1151=BTC|270=29748.20|271=0.00000000|272=20230830|273=22:02:05.697407011|59=6|126=20230830-22:10:36.714000000|37=1F1KJ21XSBR05|40=2|10=141|
MDUpdateAction, tag <279>
is the first tag in the repeating group of order events. MDUpdateAction will specify the order update event triggered in the incremental snapshot. The enumerators for MDUpdateAction are:
-
0 = NEW
-
1 = CHANGE
-
2 = DELETE
Receiving an order update message would mean clients will be required to update their order book to ensure it is reflecting the change. If an order with the Order ID37=1F1KJ21XSBR05
is received in our snapshot request, and an incremental Market Data message following with the tags |37=1F1KJ21XSBR05|279=2|
then we must omit this order from the order book.
If the order has been updated, we will receive an incremental Market Data message follows with the tags |37=1F1KJ21XSBR05|279=1|
. This will indicate a change in the order price or quantity and should be updated in the clients order book.
Once an order has been updated (279=1
) and the quantity has been increased, the order will lose its position in the processing queue. If the order quantity has been decreased then the order will maintain the position in queue, this can be monitored by use of tag <273>
MDEntryTime.