AI Agent Usage
The Flutter Voice SDK supports Voice AI Agent implementations. To get started, follow the steps described here to build your first AI Assistant. Once your AI Agent is up and running, you can use the SDK to communicate with your AI Agent with the following steps:Pre-developed AI Widget
If you don’t want to develop your own custom AI Agent interface from scratch, you can utilize our pre-developed AI Agent widget that provides a drop-in solution for voice AI interactions.Flutter Telnyx Voice AI Widget
The Flutter Telnyx Voice AI Widget is a standalone, embeddable widget that provides a complete voice AI assistant interface using the Telnyx WebRTC SDK. Repository: https://github.com/team-telnyx/flutter-telnyx-voice-ai-widget Package: https://pub.dev/packages/flutter_telnyx_voice_ai_widgetKey Features
- Configurable Dimensions: Set custom height and width for the widget
- Icon-Only Mode: Floating action button-style interface for minimal UI footprint
- Multiple UI States: Collapsed, connecting, expanded, and conversation views
- Agent Status Indicators: Shows when the agent is thinking or waiting for interruption
- Audio Visualizer: Animated bars that respond to call activity
- Theme Support: Light and dark theme configurations
- Call Controls: Built-in mute/unmute and end call functionality
- Conversation View: Full transcript with message history
- Responsive Design: Adapts to different screen sizes
Quick Integration
Documentation Structure
This directory contains detailed documentation for AI Agent integration:- Anonymous Login - How to connect to AI assistants without traditional authentication
- Starting Conversations - How to initiate calls with AI assistants
- Transcript Updates - Real-time conversation transcripts
- Text Messaging - Send text messages to AI agents during calls
Quick Start
- Login: Use
anonymousLogin()to connect to your AI assistant - Call: Use
newInvite()to start a conversation (destination ignored) - Listen: Set up
onTranscriptUpdatecallback for real-time transcripts - Message: Use
sendConversationMessage()to send text during calls
Important Notes
- AI Agent features are only available after
anonymousLogin - All calls after anonymous login are routed to the specified AI assistant
- Transcript updates are real-time and include both user and assistant messages
- Text messages appear in transcript updates alongside spoken conversation
- Standard call controls (mute, hold, end) work with AI agent calls