Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
developers:fixapi:marketdatarequest [2025/09/12 01:22] – ↷ Page moved and renamed from developers:fixapi.marketdatarequest to developers:fixapi:marketdatarequest chad | developers:fixapi:marketdatarequest [2025/09/17 01:19] (current) – chad | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== | + | ====== |
- | **Subscribing to Streaming | + | The Market |
- | ----------------------------- | + | |
- | The T4 FIX API provides | + | ===== Subscription Types (SubscriptionRequestType 263) ===== |
+ | ^ Type ^ Value ^ Description ^ | ||
+ | | Snapshot | 0 | Current | ||
+ | | Subscribe | 1 | Snapshot + continuous updates | | ||
+ | | Unsubscribe | 2 | Stop streaming data | | ||
+ | | Subscribe Incremental | 7 | Snapshot + incremental updates | | ||
- | Any time during a FIX Session, market data subscriptions can be requested for a specific market by specifying a Subscription Request Type (Tag 263=1). During the FIX session, the streaming market data (for any specific security) can also be unsubscribed (Tag 263=2). | + | ===== Throughput Levels |
+ | ^ Level ^ Value ^ Description ^ | ||
+ | | Slow Trade | 2 | Slow updates + all trades | | ||
+ | | Smart Trade | 3 | Smart buffering + all trades | | ||
+ | | Slow Smart | 4 | ~1 update/ | ||
+ | | Smart | 5 | Recommended - frequent best bid/offer | | ||
+ | | Fast Smart | 6 | More frequent best updates | | ||
+ | | All | 7 | No buffering - high bandwidth | | ||
+ | | Fast Trade | 8 | Fast updates + all trades | | ||
+ | | Trade Only | 9 | Trades only, no depth | | ||
- | A successful Market Data Request (for subscription) returns one or more Market Data messages containing one or more Market Data Entries. Currently, The T4 FIX API provides market updates with the MarketData Snapshot message (Tag 35=W) and the MarketData Incremental Refresh message (Tag 35=X). Market Data Snapshots carry multiple blocks of quote data delineated by Market Data Entries. Each Market Data Entry is a bid, an offer, a trade, settlement price of a security, the trading session high price, low price, or trade volume, open interest and low and high price limits. Market Data Entries usually have a price and a quantity (size) at a book level (for securities with market depth). For example, in an order book environment, | + | ===== Message Specification ===== |
- | Market Data requests that cannot be honored are notified via the MarketData Request Reject message. | + | **Message Direction: |
- | Subscription Types | + | ^ Tag ^ Field Name ^ Type ^ Req'd ^ Description ^ |
- | ------------------ | + | | | **Message Header** | | Y | MsgType = V | |
+ | | 262 | MDReqID | String | Y | Unique request ID | | ||
+ | | 263 | SubscriptionRequestType | Int | Y | See subscription types | | ||
+ | | 264 | MarketDepth | Int | Y | 1=Top only, 10=Full book | | ||
+ | | 265 | MDUpdateType | Int | O | Throughput level (default=5) | | ||
+ | | 267 | NoMDEntryTypes | Int | Y | Number of entry types | | ||
+ | | →269 | MDEntryType | Char | Y | 0=Bid, 1=Offer, 2=Trade, etc. | | ||
+ | | 146 | NoRelatedSym | Int | Y | Number of symbols (must be 1) | | ||
+ | | →55 | Symbol | String | Y | T4 Contract ID | | ||
+ | | →48 | SecurityID | String | Y | T4 Market ID | | ||
+ | | →167 | SecurityType | String | Y | FUT, OPT, STK, SYN, BIN | | ||
+ | | →207 | SecurityExchange | String | Y | T4 Exchange ID | | ||
+ | | →201 | PutOrCall | Int | O | Options: 0=Put, 1=Call | | ||
+ | | →107 | SecurityDesc | String | O | Set to " | ||
+ | | | **Message Trailer** | | Y | | | ||
- | The following Subscription Request Types control attributes, initiation and termination of streaming market data: | + | ===== MDEntryType Values ===== |
+ | ^ Type ^ Value ^ Description ^ | ||
+ | | 0 | Bid | Bid price/size | | ||
+ | | 1 | Offer | Offer price/size | | ||
+ | | 2 | Implied Bid | Implied bid | | ||
+ | | 3 | Implied Offer | Implied offer | | ||
+ | | 4 | Trade | Last trade | | ||
+ | | 6 | Settlement | Settlement price | | ||
+ | | 7 | High | Session high | | ||
+ | | 8 | Low | Session low | | ||
+ | | B | Volume | Trade volume | | ||
- | * **Subscribe**: | + | ===== Sample Messages ===== |
- | * **UnSubscribe**: | + | |
- | * **SnapShot**: | + | |
- | * **Subscribe Incremental**: | + | |
- | Data Throughput and Buffering Levels | + | **Subscribe |
- | ------------------------------------ | + | |
- | + | ||
- | The T4 FIX API offers several levels of data throughput. The market data subscriber can control the number of quotes and the throughput rate (received by a client application). The T4 FIX API buffers streaming market data flow and disseminates quotes at the throughput level requested by the API client. Smart Buffering is recommended. | + | |
- | + | ||
- | The following T4 buffering levels are available: | + | |
- | + | ||
- | | + | |
- | * **SmartTrade**: | + | |
- | * **SlowSmart**: | + | |
- | * **Smart**: Smart buffering (recommended), | + | |
- | * **FastSmart**: Faster version of Smart buffering; sends best bid/offer changes more often. | + | |
- | | + | |
- | * **FastTrade**: | + | |
- | * **TradeOnly**: | + | |
- | + | ||
- | Book Depth | + | |
- | ---------- | + | |
- | + | ||
- | The T4 FIX API Book Depth controls the number of book levels received for each update. Up to 10 book levels are available, depending on the security. The number of levels is requested with MarketDepth (Tag 264). Higher depth increases bandwidth usage. Level 1 is recommended for quote boards; Level 10 for full depth. | + | |
- | + | ||
- | Matching Market Data Messages against Market Data Requests | + | |
- | ---------------------------------------------------------- | + | |
- | + | ||
- | Market Data messages can be matched (by the FIX API client) through either the (unique) SecurityID (Tag 48) or by the Request ID (MDReqID - Tag 262) of the Market Data Request that initiated the streaming. SecurityID (Tag 48) is the default identification mechanism. To request identification by MDReqID, the market' | + | |
- | + | ||
- | Message Dictionary | + | |
- | ------------------ | + | |
- | + | ||
- | ^ Tag ^ Field Name ^ Req' | + | |
- | | Standard Header | Y | MsgType = V | | + | |
- | | 262 | MDReqID | Y | Must be unique. In order to unsubscribe, | + | |
- | | 263 | SubscriptionRequestType | Y | 0 = SNAPSHOT; 1 = SUBSCRIBE; 2 = UNSUBSCRIBE; | + | |
- | | 264 | MarketDepth | Y | Requested Depth of market. TopOfBookOnly = 1; FullBook = 10 | | + | |
- | | 265 | MDUpdateType | N | Type of Market Data throughput. 2 = Slow Trade; 3 = Smart Trade; 4 = Slow Smart; 5 = Smart; 6 = Fast Smart; 7 = All; 8 = Fast Trade; 9 = Trade Only | | + | |
- | | 267 | NoMDEntryTypes | Y | Number of MDEntryType fields requested. | | + | |
- | | 269 | MDEntryType | Y | 0 = Bid; 1 = Offer; 2 = Implied Bid; 3 = Implied Offer; 4 = Last Trade; 6 = Settlement; 7 = Session High; 8 = Session Low; 9 = Session Open; K = Price High Limit; L = Price Low Limit; B = Trade Volume | | + | |
- | | 146 | NoRelatedSym | Y | Number of symbols requested. | | + | |
- | | 55 | Symbol | Y | T4 Contract ID. | | + | |
- | | 48 | SecurityID | Y | T4 Market ID. | | + | |
- | | 167 | SecurityType | Y | Futures=" | + | |
- | | 207 | SecurityExchange | Y | T4 Exchange ID. | | + | |
- | | 201 | PutOrCall | N | For Options: 0 = Put; 1 = Call | | + | |
- | | 107 | SecurityDesc | N | Market Data Message Identification. Set to 262 for MDReqID matching. | | + | |
- | | 1070 | QuoteType | N | Obsolete. 1 = Ticks; 2 = Decimal | | + | |
- | | Standard Trailer | Y | | | + | |
- | + | ||
- | Sample Messages | + | |
- | + | ||
- | Subscribe to streaming data from a specific market | + | |
< | < | ||
- | >> 10/ | + | 8=FIX.4.2|9=200|35=V|49=T4Example|56=T4|52=20121010-14: |
- | [FIXMARKETDATAREQUEST] | + | 262=md-10/ |
- | [MsgSeqNum] 34 = 1891 | + | 146=1|55=ES|48=CME_20121200_ESZ2|167=FUT|207=CME_Eq|10=123| |
- | [SenderCompID] 49 = T4Example | + | |
- | [TargetCompID] 56 = T4 | + | |
- | [SendingTime] 52 = 20121010-14: | + | |
- | [MDReqID] 262 = md-10/10/2012 9:37:58 AM | + | |
- | [SubscriptionRequestType] 263 = 1 (SNAPSHOT_PLUS_UPDATES) | + | |
- | [MarketDepth] 264 = 10 | + | |
- | [MDUpdateType] 265 = 5 (SMART) | + | |
- | [NoMDEntryTypes] 267 = 3 | + | |
- | [MDEntryType] 269 = 0 (BID) | + | |
- | [MDEntryType] 269 = 1 (OFFER) | + | |
- | [MDEntryType] 269 = 2 (IMPLIED_BID) | + | |
- | [NoRelatedSym] 146 = 1 | + | |
- | [Symbol] 55 = ES | + | |
- | [SecurityID] 48 = CME_20121200_ESZ2 | + | |
- | [SecurityType] 167 = FUT (FUTURE) | + | |
- | [SecurityExchange] 207 = CME_Eq | + | |
</ | </ | ||
- | UnSubscribe | + | |
+ | **Unsubscribe | ||
< | < | ||
- | >> 10/ | + | 8=FIX.4.2|9=200|35=V|49=T4Example|56=T4|52=20121010-14: |
- | [FIXMARKETDATAREQUEST] | + | 262=md-10/ |
- | [MsgSeqNum] 34 = 1892 | + | 146=1|55=ES|48=CME_20121200_ESZ2|167=FUT|207=CME_Eq|10=234| |
- | [SenderCompID] 49 = T4Example | + | |
- | [TargetCompID] 56 = T4 | + | |
- | [SendingTime] 52 = 20121010-14: | + | |
- | [MDReqID] 262 = md-10/10/2012 9:37:59 AM | + | |
- | [SubscriptionRequestType] 263 = 2 (DISABLE_PREVIOUS_SNAPSHOT_PLUS_UPDATE_REQUEST) | + | |
- | [MarketDepth] 264 = 10 | + | |
- | [MDUpdateType] 265 = 5 (SMART) | + | |
- | [NoMDEntryTypes] 267 = 3 | + | |
- | [MDEntryType] 269 = 0 (BID) | + | |
- | [MDEntryType] 269 = 1 (OFFER) | + | |
- | [MDEntryType] 269 = 2 (IMPLIED_BID) | + | |
- | [NoRelatedSym] 146 = 1 | + | |
- | [Symbol] 55 = ES | + | |
- | [SecurityID] 48 = CME_20121200_ESZ2 | + | |
- | [SecurityType] 167 = FUT (FUTURE) | + | |
- | [SecurityExchange] 207 = CME_Eq | + | |
</ | </ | ||
- | [[developers: | ||
+ | ===== Notes ===== | ||
+ | * Smart buffering (265=5) recommended for most use cases | ||
+ | * MarketDepth=1 for quote boards, =10 for full depth | ||
+ | * Higher depth and faster updates increase bandwidth | ||
+ | * SecurityDesc=262 enables MDReqID matching in responses |