L2 Book Stream

This channel streams level 2 (L2) order book. It describes the individual price levels in the book with aggregated order quantities at each level. Only top 20 levels are included.

Update Speed

  • Updates are pushed on each block, but only if at least 0.5 seconds have passed since the last update

Subscribe Request

  • Subscribe Schema

See WsL2BookSubscriptionParams in Schema.

interface SubscribeRequest {
  op: "subscribe";
  id: number | null; // Optional client originated request identifier sent as acknowledgment in the response.
  params: WsL2BookSubscriptionParams;
}
  • Subscribe Ack Schema

See WsL2BookSubscriptionResult in Schema.

interface SubscriptionResult {
  op: "subscribe";
  id: number | null; // Optional client originated request identifier sent as acknowledgment in the response.
  result: WsL2BookSubscriptionResult | null;
  success: boolean; // Indicates if the request was successfully processed by the engine.
  connID: string;
  error: string | null; // Condition: If success is false. Error message.
  time_in: number; // The timestamp when the subscription was received on the wire, just prior to parsing data, in milliseconds.
  time_out: number; // The timestamp when the acknowledgement was sent on the wire, just prior to transmitting data, in milliseconds.
}
  • Example: Subscribe

  • Example: Subscribe Ack

Unsubscribe Request

  • Unsubscribe Schema

See WsL2BookSubscriptionParams in Schema.

  • Unsubscribe Ack Schema

See WsL2BookSubscriptionResult in Schema.

  • Example: Unsubscribe

  • Example: Unsubscribe Ack

Snapshot Response

  • Snapshot Schema

See WsDepthSnapshotData in Schema.

  • Example: Snapshot

Last updated