Start AI Assistant
Start an AI assistant on the call.
Expected Webhooks:
call.conversation.endedcall.conversation_insights.generated
Documentation Index
Fetch the complete documentation index at: https://developers.telnyx.com/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Unique identifier and token for controlling the call
Body
AI Assistant request
AI Assistant configuration. All fields except id are optional — the assistant's stored configuration will be used as fallback for any omitted fields.
The voice to be used by the voice assistant. Currently we support ElevenLabs, Telnyx and AWS voices.
Supported Providers:
- AWS: Use
AWS.Polly.<VoiceId>(e.g.,AWS.Polly.Joanna). For neural voices, which provide more realistic, human-like speech, append-Neuralto theVoiceId(e.g.,AWS.Polly.Joanna-Neural). Check the available voices for compatibility. - Azure: Use `Azure.. (e.g. Azure.en-CA-ClaraNeural, Azure.en-CA-LiamNeural, Azure.en-US-BrianMultilingualNeural, Azure.en-US-Ava:DragonHDLatestNeural. For a complete list of voices, go to Azure Voice Gallery.)
- ElevenLabs: Use
ElevenLabs.<ModelId>.<VoiceId>(e.g.,ElevenLabs.BaseModel.John). TheModelIdpart is optional. To use ElevenLabs, you must provide your ElevenLabs API key as an integration secret under"voice_settings": {"api_key_ref": "<secret_id>"}. See integration secrets documentation for details. Check available voices. - Telnyx: Use
Telnyx.<model_id>.<voice_id> - Inworld: Use
Inworld.<ModelId>.<VoiceId>(e.g.,Inworld.Mini.Loretta,Inworld.Max.Oliver). Supported models:Mini,Max. - xAI: Use
xAI.<VoiceId>(e.g.,xAI.eve). Available voices:eve,ara,rex,sal,leo.
"Telnyx.KokoroTTS.af"
The settings associated with the voice selected
- ElevenLabs Voice Settings
- Telnyx Voice Settings
- AWS Voice Settings
- Azure Voice Settings
- Rime Voice Settings
- Resemble Voice Settings
- xAI Voice Settings
Text that will be played when the assistant starts, if none then nothing will be played when the assistant starts. The greeting can be text for any voice or SSML for AWS.Polly.<voice_id> voices. There is a 3,000 character limit.
"Hello, can you tell me your age and where you live?"
Settings for handling user interruptions during assistant speech
The settings associated with speech to text for the voice assistant. This is only relevant if the assistant uses a text-to-text language model. Any assistant using a model with native audio support (e.g. fixie-ai/ultravox-v0_4) will ignore this field.
A list of messages to seed the conversation history before the assistant starts. Follows the same message format as the ai_assistant_add_messages command.
Messages sent by an end user
- User message.
- Assistant Message
- Tool Message
- System Message
- Developer Message
{
"role": "user",
"content": "Hello, I would like some help."
}
When true, a webhook is sent each time the conversation message history is updated.
A list of participants to add to the conversation when it starts.
Use this field to add state to every subsequent webhook. It must be a valid Base-64 encoded string.
"aGF2ZSBhIG5pY2UgZGF5ID1d"
Use this field to avoid duplicate commands. Telnyx will ignore any command with the same command_id for the same call_control_id.
"891510ac-f3e4-11e8-af5b-de00688a4901"
Response
Successful response upon making a call control command that includes conversation_id.
{
"result": "ok",
"conversation_id": "d7e9c1d4-8b2a-4b8f-b3a7-9a671c9e9b0a"
}