Authentication
Unlike REST, the public WebSocket does not read x-api-key headers on data frames. Authentication happens exactly once during the HTTP upgrade.
How it works
Pass your raw API key as the apiKey query parameter on the upgrade URL. The server checks it for the ws surface before completing the 101 handshake. This is native WebSocket: no Socket.IO namespace, no handshake object and no in-frame authentication step.
Connect URL
wss://stream.tickerlayer.com/?apiKey=<YOUR_API_KEY>Case-sensitive parameter name
It must be exactly apiKey. Other spellings such as api_key or APIKEY are rejected with 401 before the upgrade completes.
To try a live connection without pasting your key into the page, use the WebSocket overview.
Compared to REST
| Surface | Key goes in | Also accepted |
|---|---|---|
| REST | x-api-key header | ?apiKey= query parameter, for compatibility |
| WebSocket | ?apiKey= on the upgrade URL | Nothing else: headers on later frames are not read |
Auth errors
| Status | Meaning |
|---|---|
401 | Invalid, missing or inactive apiKey. The upgrade is rejected with no body and no frames are sent. |
403 | The key is valid, but the plan does not include WebSocket (WS_NOT_INCLUDED) or the package has ended (PACKAGE_EXPIRED), named in the JSON body's error. |