Connect
Open a WebSocket connection to:Channels
Use lowercase symbols.
Authenticate for Gated Channels
Send your CLOB API credentials on the open connection before subscribing:Subscribe
Send the channels and filters you want to follow. This request subscribes to the BTC reference price on the authenticated connection:Pin a Price Provider
Crypto and equity prices can come from more than one vendor. Every payload names its producer insource, and on price.crypto, price.equity and
price.equity.twap you can optionally pin one by adding provider to the
filter:
provider accepts chainlink or pyth. The subscribed acknowledgement
names the provider actually served. A pin the server cannot serve for that
symbol falls back to the symbol’s default provider, and the acknowledgement
names the fallback, so always read the acknowledgement rather than assuming
the pin held. Omit provider to follow the default, which is Chainlink
wherever Chainlink serves the symbol. The field is ignored on channels with a
single provider.
Values other than chainlink or pyth are rejected with a bad_filter
error.
Envelope
Data envelopes carry snapshots and live updates. Acknowledgements report the result of a request.rid when the request includes it.
Each new subscription receives an acknowledgement and one snapshot. Seed local state from the snapshot, then apply the latest price. Snapshots contain the preceding two minutes of prices, with an empty
data array when no recent data is available. Repeating an existing channel and filter returns another acknowledgement without a new snapshot.
For data envelopes:
seqis consecutive per connection and per channel, including snapshots. It resets on reconnect.tsis the producer’s event time in Unix milliseconds.snapshot: trueidentifies the initial snapshot.dropped, when present, counts frames dropped on that channel since the last delivered frame because the client fell behind.sourcenames the vendor that produced the price (pyth,massiveorchainlink): on every point of a live update and once per snapshot batch. On single-provider channels it is constant; onprice.cryptoand the equity channels a symbol’s vendor can change between connections, so re-read it after every reconnect.
https://ws-live-v2.polymarket.com/asyncapi.json for the machine-readable contract.
Unsubscribe
Send the same channel and filter withop: "unsubscribe" to stop a subscription:
unsubscribed. Both subscribe and unsubscribe
accept a single channel and filter or a subscriptions array.
Supported Symbols
Crypto Prices
For the TWAP channels, use
window_seconds: 60. Other windows do not provide data.
Every price.crypto symbol defaults to Chainlink. btcusd, ethusd,
solusd, xrpusd, dogeusd and bnbusd can also be pinned to pyth;
hypeusd and zecusd have no second provider. price.crypto.twap is
Chainlink only.
Equity Prices
price.equity supports these lowercase symbols:
Commodities serve under
cll (WTI crude oil front-month futures), hn
(Henry Hub natural gas front-month futures) and cc3m (the copper 3-month
contract price in USD). cll and hn carry the front contract’s price
under the same symbol as the contract rolls; cc3m is a single continuous
contract.
Limits and Liveness
The server sends a WebSocket ping every 25 seconds. Standard clients answer
automatically. Two missed pongs close the connection with
4002.
You can also send { "op": "ping" } to check the connection at the application
level. The server responds with pong.
Close Codes and Reconnecting
Choose the retry behavior based on the close code:
If the connection is refused with HTTP
429 or 503, use Retry-After as the minimum
wait and add jitter. Browser clients see handshake failures as 1006 and should
use exponential backoff with full jitter.
After reconnecting, authenticate again for gated channels and resend your
subscriptions, including any provider pins. Initialize from the new
snapshots and re-read source: a crypto or equity symbol can legitimately
arrive from a different vendor than before the reconnect. Sequence numbers
start over.