View on GitHub
Clone and run the full working example
Getting started
Overview
When a caller dials in, Vobiz is instructed via XML to open a raw WebSocket to your server. Pipecat’sWebsocketServerTransport receives the audio stream and routes it through a sequential AI pipeline - VAD → STT → LLM → TTS - before streaming synthesized audio back to the caller.
Architecture
How it works
1
Incoming call
When an inbound call triggers your webhook, respond with Vobiz XML instructing Vobiz to open a WebSocket stream to your server.
2
Pipecat transport
WebsocketServerTransport receives the raw audio stream. Vobiz sends base64-encoded G.711 μ-law audio frames as JSON events, which Pipecat decodes and buffers automatically.3
Sequential pipeline
Audio flows through the Pipecat pipeline - VAD detects speech, Deepgram transcribes it, OpenAI generates a response, and ElevenLabs synthesizes speech.
4
Audio response
Encode the synthesized audio and send it back over the WebSocket. Vobiz plays it to the caller in real time.
Vobiz XML hook
Your webhook endpoint must return this XML when a call arrives:Environment variables
.env