Output Data Types

This page documents the normalized messages returned by Tardis Machine replay and streaming APIs. Historical replay APIs are documented on Replaying Historical Data, and real-time streaming is documented on Streaming Real-Time Data.

Normalized data types

• trade

Individual trade

{
  "type": "trade",
  "symbol": "XBTUSD",
  "exchange": "bitmex",
  "id": "282a0445-0e3a-abeb-f403-11003204ea1b",
  "price": 7996,
  "amount": 50,
  "side": "sell",
  "timestamp": "2019-10-23T10:32:49.669Z",
  "localTimestamp": "2019-10-23T10:32:49.740Z"
}

• book_change

Initial L2 (market by price) order book snapshot (isSnapshot=true) plus incremental updates for each order book change. Please note that amount is the updated amount at that price level, not a delta. An amount of 0 indicates the price level can be removed.

When processing book_change updates: an amount of 0 means remove that price level. If you receive a removal for a price level not in your local book, ignore it. Snapshot levels may include zero-amount entries — these should also be treated as absent levels.

• book_ticker

Best bid/ask (BBO) sourced from exchange-native ticker or quote feeds (e.g., Binance bookTicker, Bybit orderbook.1). Unlike quote which derives BBO from L2 order book data, book_ticker uses the exchange's dedicated BBO stream when available.

Because it is a standalone feed, book_ticker replay can start from any point in time, whereas quote requires starting from 00:00 UTC (when the initial L2 order book snapshot is provided).

• derivative_ticker

Derivative instrument ticker info sourced from real-time ticker & instrument channels.

• book_snapshot_{number_of_levels}_{snapshot_interval}{time_unit}

Order book snapshot for selected number_of_levels (top bids and asks), snapshot_interval and time_unit. When snapshot_interval is set to 0, snapshots are taken anytime order book state within specified levels has changed, otherwise snapshots are taken anytime snapshot_interval time has passed and there was an order book state change within specified levels. Order book snapshots are computed from exchanges' real-time order book streaming L2 data (market by price).

Examples:

  • book_snapshot_10_0ms - provides top 10 levels tick-by-tick order book snapshots

  • book_snapshot_50_100ms - provides top 50 levels order book snapshots taken at 100 millisecond intervals

  • book_snapshot_30_10s - provides top 30 levels order book snapshots taken at 10 second intervals

  • quote is an alias of book_snapshot_1_0ms - provides top of the book (best bid/ask) tick-by-order book snapshots

  • quote_10s is an alias of book_snapshot_1_10s - provides top of the book (best bid/ask) order book snapshots taken at 10 seconds intervals

Available time units:

  • ms - milliseconds

  • s - seconds

  • m - minutes

• liquidation

Liquidation events sourced from exchange-native liquidation feeds. Available for exchanges that publish liquidation data (e.g., Binance forceOrder, BitMEX liquidation, OKX liquidation-orders). See which exchanges support liquidations.

• option_summary

Options instrument summary sourced from exchange-native options feeds. Available for exchanges that provide options data (e.g., Deribit, OKX Options, Binance Options). Includes greeks, implied volatility, and best bid/ask for options instruments.

• trade_bar_{aggregation_interval}{suffix}

Trades data in aggregated form, known as OHLC, candlesticks, klines etc. Not only most common time based aggregation is supported, but volume and tick count based as well. Bars are computed from tick-by-tick raw trade data, if in given interval no trades happened, there is no bar produced. For time-based bars, a bar is emitted when the first trade of the next interval arrives — not at the exact interval boundary. The bar's timestamp reflects the end of the interval period, while openTimestamp and closeTimestamp reflect actual trade times within that interval.

Examples:

  • trade_bar_10ms - provides time based trade bars with 10 milliseconds intervals

  • trade_bar_5m - provides time based trade bars with 5 minute intervals

  • trade_bar_100ticks - provides ticks based trade bars with 100 ticks (individual trades) intervals

  • trade_bar_100000vol - provides volume based trade bars with 100 000 volume intervals

Allowed suffixes:

  • ms - milliseconds

  • s - seconds

  • m - minutes

  • ticks - number of ticks

  • vol - volume size

• disconnect

Message that marks events when real-time WebSocket connection that was used to collect the historical data got disconnected.

• error

Message sent when an underlying exchange WebSocket connection error occurs. Only available for /ws-stream-normalized when withErrorMessages is set to true. The subSequentErrorsCount tracks consecutive errors without successful data — if it reaches 50, the connection is closed.

Last updated