Enumeration OrderBookRealTimeClientEvent

An enumeration providing all possible events that the OrderBookRealTimeClient can emit.

Enumeration Members

Enumeration Members

ready: "ready"

Emitted when the client is ready to receive messages.

connected: "connected"

Emitted when the client connects to the WebSocket server.

disconnected: "disconnected"

Emitted when the client disconnects from the WebSocket server.

error: "error"

Emitted when the client receives an error from the WebSocket server.

  • Includes an Error argument with more details about the error that occurred.
sync: "sync"

Emitted when the orderbook requires a sync from the REST API due to thrashing or an unexpected sequence number.

l1: "l1"

Emitted when the client receives a message from the WebSocket server.

  • Includes the market string as an argument made to the handler so that the appropriate request can be made to getOrderBookL1
l2: "l2"

Emitted when the client receives a message from the WebSocket server.

  • Includes the market string as an argument made to the handler so that the appropriate request can be made to getOrderBookL2