Predict.aiDocs
Realtime

Endpoints

The realtime surface at a glance — one WebSocket endpoint, five frame actions.

Realtime is a single WebSocket endpoint, not a set of HTTP routes:

ProtocolPathPurpose
WS/v1/wsThe realtime gateway — authenticate via Authorization: Bearer header or ?access_token= query param

Once connected, everything happens through frames:

DirectionFramePurpose
client → serversubscribeJoin a channel
client → serverunsubscribeLeave a channel
client → serverpingKeepalive
server → clientwelcomeConnection established — your connection_id and identity
server → clientackSubscribe/unsubscribe confirmed
server → clienteventA platform event on a subscribed channel
server → clienterrorA frame was rejected (bad_request, forbidden, limit_exceeded)
server → clientpongReply to your ping

Full JSON shapes for every frame are in the wire protocol.