Skip to main content

Patter

Connect any AI agent to phone calls with 10 lines of code. Patter handles telephony, speech-to-text, and text-to-speech so you can focus on your agent. Patter is an open-source SDK that gives your AI agent a voice and a phone number. Point it at any function that returns a string and Patter handles the rest — telephony, speech-to-text, text-to-speech, and real-time audio streaming. Works with Python and TypeScript, supports Twilio and Telnyx, and runs in both local and self-hosted modes.

Quick Start

Connect your first AI agent to a phone call in under 5 minutes.

Core Concepts

Understand agents, voice modes, and the audio pipeline.

Python SDK

Full documentation for the Python SDK.

TypeScript SDK

Full documentation for the TypeScript SDK.

How it works

Phone Call → Telephony (Twilio/Telnyx) → WebSocket → Patter → STT → Your Agent → TTS → Caller
Your agent receives transcribed speech as text and returns a text response. Patter handles everything else — audio streaming, transcoding, provider APIs, and real-time voice synthesis.

Key Features

  • 10 lines of code — Write an async handler. Patter does the rest.
  • Python & TypeScript — Same API surface in both languages. Pick your stack.
  • Multiple voice modes — OpenAI Realtime, ElevenLabs ConvAI, or custom Pipeline (STT + TTS).
  • Twilio & Telnyx — Both telephony providers supported. Bring your own credentials.
  • Call transfer & recording — Built-in system tools for transferring calls and enabling recording.
  • Guardrails — Block terms, run custom checks, or replace responses before they reach the caller.
  • Built-in tunnel — Cloudflare tunnel support, no ngrok required.
  • Real-time dashboard — Live metrics, latency tracking, and cost monitoring.