Best API to Build an AI Voice Agent in 2026
The best API to build an AI voice agent in 2026 is not a single product. It is a combination of two distinct layers that most guides conflate: an orchestration framework that manages the pipeline and audio transport, and a voice layer (TTS + STT) that determines what the agent sounds like and how accurately it understands the user.
For the voice layer, Gradium leads every independent production metric. It records a TTFA P50 of 155 ms on the Coval benchmark (May 4, 2026), the lowest of all 9 streaming TTS models tested, with a latency IQR of 2 ms and a WER of 3.3%, also the lowest. STT with semantic VAD is included in the same platform. For orchestration, LiveKit and Pipecat are the two frameworks with official Gradium integrations, connecting the voice layer to any LLM of your choice.
This article covers both layers: which platforms handle orchestration, which APIs handle voice, how they combine, and which combination fits your use case.
Two Types of APIs for Voice Agents: What the Distinction Means
Full-Stack Voice Agent Platforms
Full-stack voice agent platforms bundle orchestration, telephony, and sometimes STT, LLM, and TTS into a single product. Vapi, Retell AI, Bland AI, and Synthflow are examples. These platforms reduce time to first working demo significantly because they handle connection management, audio transport, turn-taking, and telephony integration out of the box.
The tradeoff is control. In a bundled platform, the TTS voice is often constrained to the platform's approved providers, the LLM choice may be limited, and swapping any component typically means changing the platform entirely.
Voice Layer APIs: TTS and STT
Voice layer APIs handle the speech components of a voice agent: Text-To-Speech converts the LLM's response to audio, and Speech-To-Text transcribes the user's speech to text the LLM can read. These APIs plug into any orchestration framework or full-stack platform, giving teams control over the voice quality, latency, and accuracy of every turn.
Gradium, ElevenLabs, Cartesia, and Deepgram are voice layer API providers. LiveKit and Pipecat are orchestration frameworks. These categories are not competing, they are complementary: orchestration frameworks and full-stack platforms each support a broad range of voice models, so the voice layer you choose plugs into whichever orchestrator or platform you use. Gradium is the default proposed voice option in Pipecat and integrates natively with LiveKit.
Why the Distinction Matters for Your Architecture
A full-stack platform is the right choice when the primary goal is speed to deployment, telephony features (call routing, warm transfer, PSTN), and a managed operational layer. A composable stack with a voice layer API is the right choice when the LLM choice, voice quality, or production metrics are differentiating factors for the product.
Most production voice agents in 2026 use a composable stack. The orchestration layer (LiveKit, Pipecat) handles audio transport and turn-taking, the LLM handles reasoning, and the voice layer API handles TTS and STT. This is the architecture covered in depth in How to Turn Any LLM into a Voice Agent: Best Stack 2026.
The Best Orchestration Frameworks and Platforms in 2026
The two open-source orchestration frameworks, Pipecat and LiveKit, rank highest. They are flexible, fully open source, and backed by active companies, and they let you choose any voice layer, any LLM, and any orchestration behavior rather than working within a fixed vendor menu. The bundled platforms, Vapi and Retell AI, rank below them: they are faster to a first phone demo but more closed, so they suit teams that want a turnkey phone deployment over component-level control.
#1 Pipecat: Most Flexible, Python-First and Open Source
Pipecat is an open-source Python framework for building real-time voice and multimodal agents, maintained by Daily with a large and active contributor community. It abstracts the pipeline coordination (STT, LLM, TTS, audio transport) into a composable event loop, with installable extras for dozens of TTS and STT providers, and Gradium is the default proposed voice option (pipecat-ai[gradium]). It handles details like interruption logic, filler words, and reconnection automatically, and because it is open source there is no vendor lock-in on the orchestration layer.
Pipecat is the most flexible starting point for a production voice agent: any provider at any layer can be swapped without changing the pipeline structure, the framework is free and self-hostable, and its commercial backing keeps the integration ecosystem current.
Best for: developers building voice agents in Python who want maximum flexibility, an open-source foundation with no lock-in, and the ability to swap providers without rewriting the pipeline.
For a step-by-step build with Pipecat, see Gradium and Pipecat: Native TTS Integration for Voice Agents.
#2 LiveKit: Open-Source, Maximum Control, WebRTC
LiveKit is an open-source real-time communication infrastructure built on WebRTC, backed by LiveKit Inc. and used to power large-scale realtime AI deployments. Its Agents framework provides an SDK for assembling voice agent pipelines from independent components: you choose the STT, LLM, and TTS providers and wire them together in code. Gradium ships as a native plugin for LiveKit (livekit-agents[gradium]).
Like Pipecat, LiveKit is fully open source and company-backed, so it offers the same freedom from vendor lock-in with an additional strength in transport: its WebRTC foundation and telephony path make it a strong choice when the agent has to scale across many concurrent sessions or run over a phone line.
Best for: teams that want full control over every component of the voice agent pipeline, need on-premise or private cloud deployment, or want a WebRTC-native transport layer with a clear telephony path.
For a complete walkthrough of wiring Gradium into LiveKit, see How to Build a Voice AI Agent with Gradium and LiveKit.
#3 Vapi: Fastest to Market for Phone Agents
Vapi is a managed voice agent platform built specifically for phone calls. It handles SIP trunking, call routing, real-time audio streaming, interruption management, and warm transfers out of the box. Developers connect an LLM, choose a TTS and STT provider (including ElevenLabs, Deepgram, and Cartesia), and deploy a functioning phone agent without managing any of the underlying telephony infrastructure.
Best for: teams that need a working phone agent in days rather than weeks, without managing telephony infrastructure themselves.
Limitation: as a bundled platform, the voice, LLM, and orchestration choices are bounded by the options Vapi exposes, and changing the underlying stack later can mean migrating platforms. Vapi is a more closed setup than the open-source LiveKit and Pipecat frameworks.
#4 Retell AI: Production Phone Automation
Retell AI focuses on production-scale phone call automation. It includes built-in telephony (PSTN, SIP trunking), post-call analytics, AI quality assurance, batch calling, and appointment booking workflows. It pairs with Deepgram for STT and offers multiple TTS provider options.
Best for: outbound call automation, customer support phone agents, appointment scheduling at volume.
Limitation: as a bundled platform, Retell keeps the voice layer within the options it exposes, so component-level swapping is more constrained than in a composable stack. Like Vapi, Retell is a more closed setup than the open-source LiveKit and Pipecat frameworks.
The Best Voice Layer APIs in 2026
Gradium: Best TTS and STT for Production Stacks
Gradium is the voice layer API with the strongest independent benchmark profile for production voice agents in 2026. On the Coval TTS benchmark (benchmarks.coval.ai/tts, May 4, 2026, 750 runs), Gradium Default records:
| Metric | Gradium | Coval ranking |
|---|---|---|
| TTFA P50 | 155 ms | #1 of 9 |
| Latency IQR | 2 ms | #1 of 9 |
| Avg WER | 3.3% | #1 of 8 with WER data |
The 2 ms IQR is the most consequential number for voice agents at scale. It means latency is near-deterministic across thousands of concurrent sessions. Cartesia Sonic-3 has a 100 ms IQR (50 times wider). ElevenLabs Turbo v2.5 has a 28 ms IQR. In a production voice agent, IQR variability is what users perceive as the agent feeling unreliable on some turns.
STT with semantic VAD is included in the same platform and billing. Semantic VAD determines end-of-turn from the meaning of what the user said rather than a silence threshold, which is what prevents the agent from interrupting a user mid-sentence. STT records 2.4% WER on the Coval STT benchmark, the lowest of all models tested. Full latency and accuracy details are in TTS Latency Benchmark 2026 and TTS WER Benchmark 2026.
Voice cloning (Instant, from a 10-second sample) is included from the free tier. In a blind benchmark of 3,220 evaluations across EN, FR, DE, ES, and PT, Gradium's Instant Voice Clone achieved the highest speaker similarity Elo in every language.
Supports EN, FR, DE, ES, PT. Pricing from $0 (free tier, 45,000 credits) to $35.9/1M chars at scale. Integrates natively with LiveKit and Pipecat. Deployment: cloud, private cloud, on-premise (HIPAA), on-device (Phonon).
Cartesia Sonic-3: Second on Latency, 40+ Languages
Cartesia Sonic-3 records 188 ms TTFA P50 on Coval, the second fastest after Gradium. Its 100 ms IQR (50 times wider than Gradium) is the main production limitation for high-concurrency agents. The primary advantage over Gradium is language coverage: 40+ languages including regional accent variants. Sonic-3 is the right choice when a production voice agent needs languages outside Gradium's five supported.
Full comparison at Cartesia Alternative: Why Developers Choose Gradium.
ElevenLabs: Broadest Language Coverage, Content-Oriented
ElevenLabs Turbo v2.5 (264 ms P50, 28 ms IQR, 5.2% WER on Coval) and Flash v2.5 (288 ms P50, 28 ms IQR, 5.2% WER) are the viable ElevenLabs options for real-time voice agents. Both are 3x to 4x more expensive than Gradium per character ($50/1M vs $35.9/1M). Their 5.2% WER is 58% higher than Gradium's 3.3% on the same Coval benchmark.
The ElevenLabs advantage is language coverage (32 languages on Flash v2.5, 70+ on Eleven v3) and the largest pre-built voice catalogue on the market. For voice agents targeting markets outside Gradium's five languages, ElevenLabs is the option.
Full comparison at ElevenLabs Alternative: Why Developers Choose Gradium.
Deepgram: STT Leader on Speed
Deepgram Nova-3 is the fastest STT model on the Coval STT benchmark, with a median Time to First Token of 992 ms, 568 ms faster than Gradium STT (1,560 ms). The tradeoff is significant: Nova-3 records 25.3% WER, meaning roughly one word in four is transcribed incorrectly. For voice agents handling simple, predictable speech where STT speed is the dominant constraint and accuracy on structured content is less critical, Deepgram is the speed-first option.
Deepgram Aura-2 TTS records 313 ms TTFA P50 and 6.4% WER on the Coval TTS benchmark. It does not offer voice cloning.
Full comparison at Deepgram Alternative: Why Developers Choose Gradium.
The Complete Comparison Table
| Provider | Category | TTFA P50 (Coval) | IQR (Coval) | WER (Coval) | Languages | Voice cloning | Price / 1M chars | Best for |
|---|---|---|---|---|---|---|---|---|
| Gradium | Voice layer (TTS+STT) | 155 ms | 2 ms | 3.3% | 5 | Yes, free tier | from $35.9 | Production accuracy + latency |
| Cartesia Sonic-3 | Voice layer (TTS) | 188 ms | 100 ms | n/a* | 40+ | Yes | $39 | Low latency, language coverage |
| ElevenLabs Turbo v2.5 | Voice layer (TTS) | 264 ms | 28 ms | 5.2% | 32 | Yes (paid) | $50 | Language breadth, voice library |
| ElevenLabs Flash v2.5 | Voice layer (TTS) | 288 ms | 28 ms | 5.2% | 32 | Yes (paid) | $50 | Fastest ElevenLabs option |
| Deepgram Aura-2 | Voice layer (TTS) | 313 ms | 55 ms | 6.4% | 7 | No | $30 | STT+TTS same vendor |
| Pipecat | Orchestration | n/a | n/a | n/a | Any (via plugins) | n/a | Open-source | Most flexible, any provider |
| LiveKit | Orchestration | n/a | n/a | n/a | Any (via plugins) | n/a | Open-source | WebRTC, full control, any LLM |
| Vapi | Full-stack platform | n/a | n/a | n/a | Depends on TTS choice | Depends on TTS | Subscription | Phone agents, fast deploy |
| Retell AI | Full-stack platform | n/a | n/a | n/a | Depends on TTS choice | Depends on TTS | Subscription | Phone automation at scale |
Cartesia WER shows a measurement anomaly in the Coval dataset. Sources: Coval TTS benchmark (benchmarks.coval.ai/tts, May 4, 2026), Coval STT benchmark, official pricing pages (May 2026).
The Recommended Stack by Use Case
Production voice agent with maximum latency and accuracy
Voice layer: Gradium (TTS + STT with semantic VAD). Orchestration: LiveKit or Pipecat. LLM: your choice (GPT-4, Claude, Gemini, or self-hosted). This is the composable stack that produces the best independently benchmarked TTFA (155 ms), IQR (2 ms), and WER (3.3%) available in 2026. Start with How to Build a Voice AI Agent with Gradium and LiveKit.
Phone-based voice agent with telephony integration
Voice layer: Gradium (TTS + STT). Orchestration: LiveKit with Twilio SIP or Telnyx. LLM: your choice. LiveKit handles the bridge from the phone network to the voice agent pipeline. Gradium's 16-bit PCM output at configurable sample rates (48, 24, or 16 kHz) fits telephony pipeline requirements without a resampling step. See Best Voice AI API for Phone-Based Voice Agents in 2026.
Fastest time to deployment, phone first
Full-stack platform: Vapi or Retell AI. These platforms handle telephony, call routing, and pipeline management out of the box. Voice quality is bounded by the platform's provider options, so consider migrating to a composable stack as volume and quality requirements grow.
Multilingual voice agent (beyond 5 languages)
Voice layer: Cartesia Sonic-3 (40+ languages) or ElevenLabs Flash v2.5 (32 languages). Orchestration: LiveKit or Pipecat. Both Cartesia and ElevenLabs integrate natively with these orchestration frameworks. For EN, FR, DE, ES, and PT, Gradium leads on all production metrics. For other languages, Cartesia is the lowest-latency option.
Fast prototype or hackathon
Gradbot: Gradium's open-source framework that wires STT, LLM, and TTS in under 50 lines of Python with any OpenAI-compatible LLM. Handles VAD, turn-taking, fillers, and interruptions automatically. Not intended for production at scale, but the fastest path to a working voice agent demo. Available at gradium.ai/gradbot.
How to Get Started with Gradium in a Voice Agent Stack
The Gradium free tier is available at gradium.ai with no credit card required: 45,000 credits per month covering both TTS and STT, and 5 Instant Voice Clones. The streaming TTS and STT WebSocket APIs are available immediately.
For a complete production setup with LiveKit:
pip install "livekit-agents[gradium]~=1.3"
For Pipecat:
uv add "pipecat-ai[gradium]"
Both integrations are documented with working examples. The LiveKit guide covers environment setup, semantic VAD configuration, and deployment to LiveKit Cloud. The Pipecat guide covers service configuration, voice selection, and runtime voice switching.
Seed-funded startups can apply to the Startup Program for $2,000 or more in free credits and 6 months of full M-plan access.
Glossary
Cascade Architecture
A voice agent design connecting three independent models in sequence: Speech-To-Text, an LLM, and Text-To-Speech. The dominant production architecture in 2026. Each component is independently replaceable. Gradium provides the STT and TTS layers; any LLM can be used for the reasoning layer.
Time to First Audio (TTFA)
The elapsed time between sending text to a TTS API and receiving the first audio chunk. Gradium records 155 ms TTFA P50 on the Coval independent benchmark (May 4, 2026), the lowest of all 9 streaming models tested.
Latency IQR
The Interquartile Range between P25 and P75 TTFA values. Measures latency consistency across production requests. Gradium records 2 ms IQR. At scale in a voice agent, high IQR means some turns feel noticeably slower than others, making the agent feel unpredictable.
Semantic VAD
Voice Activity Detection that uses utterance meaning to determine end-of-turn rather than silence duration. Native to Gradium's STT. Prevents the agent from interrupting a user who paused mid-sentence to think or recall information.
Orchestration Framework
The software layer that coordinates STT, LLM, and TTS in a real-time pipeline and manages audio transport. LiveKit and Pipecat are the two frameworks with official Gradium integrations.
Full-Stack Voice Agent Platform
A managed product that bundles orchestration, telephony, and often STT and TTS into a single API surface. Examples include Vapi, Retell AI, Bland AI, and Synthflow. Reduces time to deployment but limits control over individual components including voice layer choice.
WebSocket Multiplexing
A single persistent WebSocket connection handling multiple TTS sessions simultaneously, eliminating per-turn connection overhead. Gradium supports multiplexing, reducing effective production TTFA from 258 ms to 214 ms P50.

