Expand description
Bybit WebSocket API client implementation.
This module provides the WebSocketConnector and WebSocketConnection for interacting
with the Bybit WebSocket API. It enables real-time streaming of market data, such as ticker
updates, and is used internally to implement the AssetInfoProvider trait for asset workers.
This module provides:
- Establishes WebSocket connections to Bybit servers
- Subscribes and unsubscribes to ticker streams for specified symbols
- Processes incoming WebSocket messages, including ticker updates and ping events
- Transforms WebSocket messages into
AssetInfofor use in workers - Handles connection management, including closing connections gracefully
Structsยง
- WebSocket
Connection - Represents an active WebSocket connection to Bybit.
- WebSocket
Connector - A connector for establishing WebSocket connections to the Bybit WebSocket API.