AI and Humans, in Perfect Communication Harmony
Built for the agentic era.
$ pip install --pre agentduet
from agentduet import SessionManager, Call
async with SessionManager(config) as sm:
@sm.on_session_notification
async def handle(noti):
session = await sm.open_session(noti.session_id)
@session.on_incoming_call
async def on_call(call: Call):
await call.answer()
async for chunk in call.audio_stream():
await call.send_audio(chunk) # echo
await session.ready()Live call
connected
codec: opus · latency: 120ms
Give your agents a real phone line
Everything an autonomous agent needs to talk to the world, from SIM to voice, messaging and compliance.
Connect to SIM
Provision programmable SIMs and give agents a real number on any network, with global roaming.
Connect to Agent
Bridge live calls and threads straight into your agent runtime with streaming events.
Inbound & Outbound Calls
Place and receive carrier-grade voice calls with low-latency audio your agents can speak on.
RCS & SMS
Rich messaging and reliable SMS fallback, with delivery receipts and two-way threads.
WhatsApp API
Reach billions on WhatsApp with verified business messaging your agents drive end to end.
Connected to MCP
Expose telecom actions as MCP tools so any compatible agent can call, text and verify.
Telco Grade Security
Carrier-level encryption, fraud controls and isolation across every channel and number.
ISO 27001, 27017 & 27018 Certified
Audited information security, cloud security, and cloud privacy controls you can trust for regulated deployments.
The SDK of your choice
Ship agent telephony in minutes. Available today in public beta for Python 3.11+, with Go and Java on the way.
$ pip install --pre agentduet
from agentduet import SessionManager, Call
async with SessionManager(config) as sm:
@sm.on_session_notification
async def handle(noti):
session = await sm.open_session(noti.session_id)
@session.on_incoming_call
async def on_call(call: Call):
await call.answer()
async for chunk in call.audio_stream():
await call.send_audio(chunk) # echo
await session.ready()
await sm.run_forever()Voice and text on one session
A Session is your live channel to a contact. Stream real-time audio through a Call and exchange WhatsApp messages on the same session, while AgentDuet manages the connection for you.
- Low-latency PCM audio with pull-based flow control
- Instant interruption: clear the buffer the moment the caller cuts in
- Pick your auth: API key or mTLS client certificates
- Auto-reconnect with heartbeat and exponential backoff
Multiple endpoints, one SDK
AgentDuet lets you connect your agents to the device of your choice. One integration reaches your users on the phone, on WhatsApp, and inside your own app.
Reach any phone line
Connect your agents to a landline or SIM card. Place and receive real phone calls without touching telecom plumbing.
Meet users where they chat
Bring your agents to WhatsApp for voice and messaging. Your contacts talk to an agent in the app they already use every day.
Drop into your own app
Connect your agents to a client app of your choice. Embed live voice and chat straight into your product experience.
Stops talking the moment the caller cuts in
Outgoing audio is buffered with pull-based flow control for smooth playback. When your model signals an interruption, clear the buffer and the agent goes quiet instantly, no talking over the caller.
await call.clear_send_audio_buffer()- Pull-based flow control keeps playback smooth
- Buffer clears the queued response instantly
- Next send_audio() starts the new turn cleanly
agent speaking
caller interruptsbuffer cleared
Telco grade security, ISO 27001, 27017 & 27018 certified
Carrier fraud protection and audited controls across information security, cloud security, and cloud privacy. Built to the standards regulated teams require.
Works with your preferred AI models and Tools:
Connect AgentDuet to leading real-time and voice models, or plug in your own. The telecom layer stays the same.