OpenAI Live API tip: control voice sessions from your backend via sideband WebSocket
pbbakkum · x · 2026-10-21
Developer pbbakkum shared a lesser-known but highly useful pattern for OpenAI's Live API (gpt-live-1) in production:
- When a web/mobile client connects directly to gpt-live-1 voice, the client-side code must be treated as untrusted
- You don't need to proxy all traffic for security guarantees: open a sideband WebSocket from your app backend to control the session — e.g. responding to function calls, updating instructions/tools, executing private business logic
- The diagram shows the full architecture: client ↔ Live API over WebRTC for audio and allowlisted data-channel events, trusted app server receiving session events (transcripts, tool calls) and sending commands via sideband
This keeps direct-connection latency while giving server-side guarantees equivalent to proxying.
Related event: Dev shares backend sideband trick for OpenAI Live API(2 posts)→
More from coding & agent
- Hypothesis Dreamer Agent: A Weekly AI Prompt for Generating Research Ideas — nlarusstone · 2026-10-21
- Dev Builds 'Sandman' Grok Bot to Manage Context Across a 33-Bot Fleet — alexcovo_eth · 2026-10-21
- Hallance launches: an AI aiming to do the work of an entire IT consultancy — TAbrodi · 2026-10-21
- SherpaLabs launches RL environments for finance, coding, quant; top models pass only ~6% on its finance benchmark — ycombinator · 2026-10-21
- The 20x cost trap: AI agents cost 10x traditional AI and 20x conventional software — DavidLinthicum · 2026-10-21
- YC F26's WonderSearch Launches Zero-Embedding Search Built for AI Agents — Scobleizer · 2026-10-21