Skip to main content
POST
Create a new session to start real-time voice processing. The session establishes a WebSocket connection for streaming audio and receiving transcripts/translations.
Do not send a top-level provider object on create. Specify telephony with routing only (for example routing.phone_number or routing.connection_id). A top-level provider string on the response indicates the resolved carrier (twilio, telnyx, sip, etc.) and must not be confused with request fields.

Request Body

string
required
The session mode:
  • bidirectional_translation - Both parties hear translated speech
  • assistive_translation - Agent hears original, customer hears translation
  • ai_agent - AI-powered voice agent handles the conversation
  • help_chat_voice - Voice-enabled help desk assistant
string
Language code for Party A (e.g., en, es, de). Optional - if omitted, language is auto-detected.
string
Language code for Party B (e.g., en, es, de). Optional - if omitted, language is auto-detected.
object
Telephony routing. Omit to use your organization’s default route.Exactly one routing method should be supplied (phone number, SIP, connection, or inherited default).
object
Optional audio transport hints (encoding, sample rate, channels). Omit unless your telephony path needs non-default values.
object
Voice synthesis hints for translated audio.
object
object
Only for ai_agent mode. Omit for translation modes.
object
Custom key-value pairs to attach to the session (e.g., {"customer_id": "123"}).

Response

string
Session identifier (e.g., sess_01HXYZ123456789).
string
Always session.
string
created, active, or ended.
string
The session mode.
string
Echoed field on the session object. You do not need to set or interpret it for a standard integration.
string
Resolved source language. null if using auto-detection.
string
Resolved target language. null if using auto-detection.
object
WebSocket connection details.
string
Response only — resolved telephony carrier: twilio, telnyx, sip, or webrtc when applicable. This is not a request field; select routes with routing on create.
string
Phone number for this session (if applicable).
object
Optional linked telephony reference when present (id, object, provider, and provider-specific identifiers such as carrier call IDs).
object
object
Custom metadata attached to the session.
string
Creation timestamp (ISO 8601).
Samples below: The minimal cURL uses default org routing (no routing in the body). The second cURL adds routing.phone_number to match Quick Start. For production, send Idempotency-Key on every create (see Idempotency).