Patter: Outbound Calls
April 14, 2026 · View on GitHub
Patter: Outbound Calls
Place outbound calls with answering machine detection (AMD) and voicemail drop.
Part of the Patter Voice AI SDK.
Prerequisites
Quick Start
Python
cd python
cp ../.env.example .env # fill in your keys
pip install -r requirements.txt
python main.py
TypeScript
cd typescript
cp ../.env.example .env # fill in your keys
npm install
npx tsx main.ts
Environment Variables
| Variable | Required | Description |
|---|---|---|
OPENAI_API_KEY | Yes | OpenAI API key with Realtime access |
TWILIO_ACCOUNT_SID | Yes | Twilio account SID |
TWILIO_AUTH_TOKEN | Yes | Twilio auth token |
TWILIO_PHONE_NUMBER | Yes | Your Twilio phone number (E.164) |
WEBHOOK_URL | No | Public URL for webhooks (auto-tunneled if omitted) |
What This Demonstrates
phone.call()for placing outbound callsmachineDetectionto detect answering machines via AMDvoicemailMessageto leave a pre-recorded message on voicemail- Lifecycle callbacks for call events
Next Steps
- Inbound Agent — answer calls with AI
- Tool Calling — add webhook-backed tools
- Custom Voice — pipeline mode with Deepgram + ElevenLabs
- Full documentation
- All templates
License
MIT