Quote Realtime
You can access any endpoint via websockets if you have subscriped to the premium or enterprise package
To access quote realtime data use both subscribe
and unsubscribe
action. You will receive an update if the quote data has changed.
- Subscribe:
{"action": "subscribe", "channel": "quote", "symbol": "AAPL"}
- Unsubscribe:
{"action": "unsubscribe", "channel": "quote", "symbol": "AAPL"}
Example
1. Connect to the websocket
CLI command:
wscat -c "wss://ws.bavest.co/v0" -H "x-api-key: <API KEY>"
2. Subscribe to forex data
{"action": "subscribe", "channel": "quote", "symbol": "AAPL"}
3. Unsubscribe if needed
{"action": "unsubscribe", "channel": "quote", "symbol": "AAPL"}
Updated 6 months ago