faint-gold-41196
11/28/2025, 7:58 AMtall-airline-16756
11/28/2025, 7:59 AMtall-airline-16756
11/28/2025, 7:59 AMsip:<your-project-domain>.sip.livekit.cloud, enable TLS transport and SRTP.
• Or use a TwiML Bin that dials your LiveKit SIP URI and assign it to your Twilio number.
(See: Inbound calls with Twilio Voice.)
1. Create a LiveKit inbound trunk that maps your Twilio number to LiveKit
• Example trunk JSON includes the Twilio number and, if needed, auth_username / auth_password.
• Create it with lk sip inbound create <file>.
(See: SIP inbound trunk.)
1. Create a dispatch rule to route incoming calls to rooms and agents
• Dispatch rules can create rooms with a prefix (e.g., call-) and list the agent(s) to dispatch.
• Create with lk sip dispatch create <file>.
(See: Agents telephony integration.)
1. Ensure your agent is configured for explicit dispatch
• Give the agent a matching name in code (e.g., agent_name: "my-agent") so the dispatch rule can start that agent when calls arrive.
1. Test the flow
• Call your Twilio number → Twilio forwards to LiveKit → inbound trunk matches the number → dispatch rule creates room and starts agent → agent joins and answers.
Quick troubleshooting tips:
• If agent doesn’t answer: confirm the agent name in code matches the dispatch rule.
• If call is rejected: verify SIP URI format and TLS on Twilio.
• If no audio: check SRTP/codec settings and trunk noise-cancellation options.
If you want, tell me:
• Which Twilio method you plan to use (Elastic SIP Trunking or TwiML), and
• Your agent name (as defined in code),
and I’ll give the exact example config snippets you can drop into your setup.
Sources: Secure trunking | LiveKit docs | Inbound calls with Twilio Voice | LiveKit docs | SIP inbound trunk | LiveKit docs | Agents telephony integration | LiveKit docs | SIP participant | LiveKit docs