Skip to main content

What Is a Speech Pipe?

A Speech Pipe in Unpod ties together a voice profile (STT + TTS), telephony (phone numbers), and a pointer to your agent brain into a single deployable unit. When a call arrives on a number attached to the pipe, the orchestrator dispatches it to your AgentRunner process.
Animated Speech Pipe flow showing a phone number routing into a Speech Pipe, the voice profile connecting to the STT/TTS stack, and dispatch to AgentRunner and CallContext.

Creating a Pipe

create() parameters


Listing Pipes

Pipe fields


Getting a Single Pipe


Updating a Pipe


Deleting a Pipe

Deleting a pipe does not automatically detach phone numbers. Detach all numbers before deleting to avoid orphaned routing.

How the Pipe Reaches Your Brain

The pipe never calls your brain over HTTP. On every call the orchestrator dispatches the session to a worker, and the worker connects to your AgentRunner over a WebSocket bridge (text in / text out). There are two ways the pipe finds that runner:
  1. By agent_id (preferred). Run an AgentRunner with the same agent_id as the pipe. It self-registers its bridge serving_url; the orchestrator picks a registered, least-loaded runner per call. You never hardcode a URL.
  2. By agent_endpoint (static fallback). Set the pipe’s agent_endpoint to a fixed wss://... bridge URL. Used only when no runner is registered for agent_id. This is a WebSocket URL, not an HTTP endpoint.
agent_endpoint is not an HTTP webhook - the orchestrator does not POST to it. It is the WebSocket bridge URL your AgentRunner serves on.

Bridging a Remote HTTP Brain

If you already have a chatbot or API (any language) and want to voice-enable it, run an AgentRunner and set its dialog brain to an HTTPAdapter. The adapter POSTs each user turn to your endpoint from inside the runner:

HTTPAdapter Protocol

The HTTPAdapter sends a POST on every user turn:
Your endpoint must respond with:
This protocol is not OpenAI-compatible. It is a simple text-in / text-out interface - your endpoint owns all LLM or chatbot logic. Forward to OpenAI, Gemini, a rules engine, or anything else under the hood. See Adapters for the full HTTPAdapter contract (streaming, assist(), error surfaces).

The recommended pattern for production is a dedicated AgentRunner process:
The agent_id in AgentRunner must match the pipe’s agent_id in the platform. The orchestrator uses it to route dispatches to the correct runner worker.

Next Steps

SDK Setup

Install and configure the AgentRunner for production.

Session Controls

Say, transfer, end, and record during live calls.