For the complete documentation index, see llms.txt. This page is also available as Markdown.

Connecting

Connecting to the sFOX Connect WebSocket feed gives you access to real-time updates about your users and market data

Environment

Endpoint

Production

wss://ws.sfox.com/ws

Staging

wss://ws.staging.sfox.com/ws

const WebSocket = require('ws');

const ws = new WebSocket('wss://ws.sfox.com/ws');

// don't forget to subscribe (see below)
ws.on('message', function(data) {
    // Do something with data
    console.log(data);
});
import asyncio

import websockets

async def main(uri):
    async with websockets.connect(uri) as ws:
        # don't forget to subscribe (see below)
        async for msg in ws:
            print(msg)


asyncio.run(main("wss://ws.sfox.com/ws"))

Last updated