SQLRooms Query Workbench – WebSocket backend
This example uses the WebSocket DuckDB connector and must run alongside the Python server in server/sqlrooms-server. By default, the client connects to ws://localhost:4000.
Start the DuckDB server
Recommended (using uv):
cd server/sqlrooms-server
uv run sqlrooms-serverOr install and run via pip:
pip install sqlrooms-server sqlrooms-server
Notes:
- If you enable auth, add
--auth-token YOUR_TOKENwhen starting the server. The client must send the same token on connect. - See
server/sqlrooms-server/README.mdfor full options and protocol details.
Run this example
From the repo root:
pnpm build
cd examples/query-websocket
pnpm devOpen the URL printed by Vite. Ensure the server continues running on port 4000, or update the connector wsUrl if you change the port.