Urgent.News

What's breaking now, across thousands of outlets.

AI

Build a Natural Language IVR with Telnyx Call Control and AI Inference

Nobody likes phone trees. "Press 1 for billing, press 2 for support." Miss an option? Start over. It is friction at its worst. The voice-ivr-with-agent-backend example replaces that with a natural language conversation. Callers just say what they need, and the app routes them to the right department. Code: https://github.com/team-telnyx/telnyx-code-examples/tree/main/voice-ivr-with-agent-backend…

The "build a natural language IVR with Telnyx Call Control and AI Inference" example replaces traditional phone trees with a more conversational voice IVR. By using Python/Flask and Telnyx's Call Control, AI Inference, and KV store, callers can speak their needs and be routed to the appropriate department. The app handles inbound calls by answering with Call Control, gathering speech input, and using AI inference to generate a dynamic greeting and route the caller's intent to the correct department.

If the AI inference fails, the app defaults to a static greeting or keyword matching. After a certain number of turns, the call transfers to a default operator. The app uses Telnyx primitives for Call Control and AI Inference, a KV store for menu configuration, and an agent state machine to track call state and retry logic. The AI Inference component uses OpenAI's chat completions API for dynamic greetings and intent routing.

Webhooks are verified with signature verification to prevent spoofed requests. The agent state machine is implemented in an IVRAgent class. The example provides management APIs for updating the menu configuration, retrieving it, listing active agents, and a health check. To use the example, clone the code repository, set up a virtual environment, install the required packages, fill in your Telnyx API credentials, and run the app.

For production use, consider adding a persistent KV store, caller ID personalization, call queues for holds, authentication on management endpoints, and monitoring for LLM latency and fallback rates.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in AI

Google Gemini Expands Connected Apps for Planning, Creation and Everyday Tasks

Google has announced a new slate of connected apps and services for the Gemini App , expanding the assistant's ability to support planning, creation and task management from one conversational…

  • Google Gemini App introduces connected apps for planning, creation, and everyday tasks.
  • Rollout is gradual with varying availability, permissions, and integration depth.

One AI Chat Is Not a Research Workspace

Originally published on omid.dev . I was deep in a research thread that was not going to become a weekend post. The topic started small: juniors asking an AI to format code that Prettier already owns…

  • One AI chat session is not equivalent to a research workspace
  • Junior developers misuse AI tools, losing essential knowledge
  • Separate organized workspace needed for messy research thoughts

More from Friday 28 August →