Substreams WebSockets service — stream decoded blocks, swaps & transfers in real time.
    Read-only preview
    You're browsing the public WebSockets reference. Sign in to open a live stream with your team's API key.

    QuickstartBeta

    Open a WebSocket, subscribe to a network@table stream, and start receiving decoded blocks in real time. Pick a stream below — then drop the URL into wscat, Node, or the browser.

    Endpoint
    WS
    1# npm i -g wscat
    2wscat -c "wss://ws.pinax.network/ws/solana@swaps?token=<YOUR_JWT>"
    No API key loaded — samples show a <YOUR_JWT> placeholder. Open Try it to paste a token and stream live.
    Available streams (loading…)live from GET /streams

    Endpoint

    Stream selectors take the form <network>@<table>. Wildcards are accepted on either side.

    WSwss://ws.pinax.network/ws/<network@table>
    URLModeEnvelope
    /ws/<a>Single channelRaw payload
    /ws/<a>/<b>/…Multi channelWrapped
    /stream?streams=<a>/<b>/…Combined, query stringWrapped

    When wrapped, every payload is delivered as { "stream": "<id>", "data": <raw> }. Bare /ws with no streams returns HTTP 400 — use /ws/*@* to explicitly opt into every stream.

    Multi-network selectors

    The <network> side accepts a comma-separated list to subscribe to the same table across chains in one selector — <n1>,<n2>,…@<table>. The server expands it into one entry per network, and LIST_SUBSCRIPTIONS echoes the expanded form.

    wss://ws.pinax.network/ws/solana,base,mainnet@swaps
    // LIST_SUBSCRIPTIONS → ["solana@swaps", "base@swaps", "mainnet@swaps"]

    Works on URL paths (/ws/…, /stream?streams=…) and in SUBSCRIBE / UNSUBSCRIBE params. A bare * can't be mixed with named networks (use * alone); empty or duplicate entries are rejected, and the comma list is not allowed on the <table> side.