Overview
The Polymarket Real-Time Data Socket (RTDS) is a WebSocket-based streaming service that provides real-time updates for various Polymarket data streams. The service allows clients to subscribe to multiple data feeds simultaneously and receive live updates as events occur on the platform.
<Note>Polymarket provides a Typescript client for interacting with this streaming service. Download and view it's documentation here</Note>
Connection Details
- WebSocket URL:
wss://ws-live-data.polymarket.com - Protocol: WebSocket
- Data Format: JSON
Authentication
The RTDS supports two types of authentication depending on the subscription type:
CLOB Authentication: Required for certain trading-related subscriptions
key: API keysecret: API secretpassphrase: API passphrase
Gamma Authentication: Required for user-specific data
address: User wallet address
Connection Management
The WebSocket connection supports:
- Dynamic Subscriptions: Without disconnecting from the socket users can add, remove and modify topics and filters they are subscribed to.
- Ping/Pong: You should send PING messages (every 5 seconds ideally) to maintain connection