Configure an Atom number in LiveKit

Voice
Connect an Atom telephone number to an AI agent in LiveKit Cloud for inbound and outbound calls. Atom provides the telephone service and LiveKit connects each call to a room where your agent can answer.
This guide covers LiveKit Cloud, not a self-hosted installation. SMS is not included.

Before you begin

Make sure you have:
  • Access to the Atomic portal to create and manage a Voice Service.
  • Access to your LiveKit Cloud project.
  • A deployed LiveKit AI agent.
  • An Atom Voice Service and an assigned telephone number or access to create them using the steps below.
  • A Windows computer with PowerShell for the manual outbound CLI procedure. The LiveKit CLI is a command-line tool for managing your project and placing calls.
  • A telephone number you control for the call tests.
Use your own service, number and project details throughout this guide.
Allowed addresses: LiveKit documents that this feature requires project enablement. If it is unavailable, ask LiveKit support to enable it before following the inbound setup. Do not remove the source-address restriction to work around it.
Keep credentials secure: Do not include the VOIP password, LiveKit API keys or API secrets in screenshots, documentation, support tickets or chat messages.

Create the Atom voice service

Navigate: Services > Voice in the Atomic portal.
Step 1: Sign in to the Atomic portal.
Step 2: In the sidebar, open Services then select Voice.
Voice services page in the Atom portal, with Voice selected in the Services sidebar and Add Service…
Voice services page in the Atom portal, with Voice selected in the Services sidebar and Add Service…
Step 3: Select Add Service.
Select Add Service to create a voice service
Select Add Service to create a voice service
Step 4: Select the Customer for the service.
Add voice service form with the Customer dropdown set to Atom Customer.
Add voice service form with the Customer dropdown set to Atom Customer.
Customer not listed: If the customer does not exist yet, follow the create a customer guide before continuing.
Step 5: Set Voice Service Type to SIP Trunk.
Step 6: Give the service a clear name that identifies its LiveKit use.
Service plan form with the Service Name field highlighted for naming the ElevenLabs service
Service plan form with the Service Name field highlighted for naming the ElevenLabs service
Step 7: Save the service.

Order and assign a number

Step 1: Follow the number-ordering guide to order a number through Number Request.
Step 2: When the number is available, assign it to the Voice Service you created for LiveKit.
Step 3: Record the full number, including its country code. You will use it in the trunk and caller-ID settings below.

Configure inbound calling

Inbound calls follow this route:
text
Caller > Atom number > LiveKit inbound trunk > dispatch rule > room > AI agent

Create an inbound trunk in LiveKit

Navigate: Telephony > SIP trunks in your LiveKit Cloud project.
Step 1: Open your LiveKit Cloud project and select Telephony.
LiveKit Cloud project overview with the Telephony menu item highlighted
LiveKit Cloud project overview with the Telephony menu item highlighted
Step 2: Select SIP trunks.
LiveKit Telephony dashboard with SIP trunks highlighted in the sidebar
LiveKit Telephony dashboard with SIP trunks highlighted in the sidebar
Step 3: Select Create new trunk > Inbound trunk.
LiveKit SIP trunks page with the Create new trunk menu open and Inbound trunk highlighted
LiveKit SIP trunks page with the Create new trunk menu open and Inbound trunk highlighted
Step 4: Enter these settings:
LiveKit inbound trunk form with trunk name, numbers, and allowed addresses highlighted above option…
LiveKit inbound trunk form with trunk name, numbers, and allowed addresses highlighted above option…
3 of 3 rows
Trunk nameA clear name such as Atomic Inbound
NumbersYour assigned Atom number, including its country code
Allowed addresses52.65.130.216/32
Step 5: Keep these optional settings:
3 of 3 rows
Media encryption (SRTP)Media encryption disabled
Include headersNo headers
Enable KrispOff
Step 6: Select Create and confirm that the trunk appears under Inbound.
LiveKit SIP trunks page with the new Atom inbound trunk listed under Inbound.
LiveKit SIP trunks page with the new Atom inbound trunk listed under Inbound.
Unencrypted call audio: This configuration disables SRTP on both the inbound and outbound trunks. The telephone audio on these connections is not encrypted with SRTP.

Create a dispatch rule for the AI agent

A dispatch rule connects an incoming call to a room and tells LiveKit which agent should join it.
Navigate: Telephony > Dispatch rules in LiveKit.
Step 1: Open Telephony > Dispatch rules.
LiveKit Telephony > Dispatch rules page with the Create new dispatch rule button highlighted
LiveKit Telephony > Dispatch rules page with the Create new dispatch rule button highlighted
Step 2: And then select Create a new dispatch rule.
Step 3: Enter these settings:
Dispatch rule setup with the rule name, type, and room prefix fields highlighted.
Dispatch rule setup with the rule name, type, and room prefix fields highlighted.
3 of 3 rows
Rule nameA clear name such as Atomic Inbound Calls
Rule typeIndividual
Room prefixLeave blank
Step 4: Under Agent dispatch, select your deployed AI agent.
Step 5: Keep the other agent settings at their defaults unless your deployment requires different values.
LiveKit dispatch rule form with Atom-LiveKit agent settings and the Atomic Inbound trunk selected
LiveKit dispatch rule form with Atom-LiveKit agent settings and the Atomic Inbound trunk selected
Step 6: Under Inbound routing, select Trunks.
Step 7: Select the Atomic Inbound trunk you created above.
Step 8: Select Create.

Add the SIP Incoming Trunk in Atom

Navigate: Services > Voice > Manage > Connections > SIP Incoming Trunk in the Atomic portal.
Step 1: In LiveKit, open Telephony > SIP trunks and copy the value shown in the SIP URI panel.
LiveKit SIP trunks page with the SIP URI value highlighted for copying
LiveKit SIP trunks page with the SIP URI value highlighted for copying
Step 2: In the Atomic portal, open Services > Voice.
Step 3: Find the Voice Service created for LiveKit and select Manage.
Voice services list with the Manage button highlighted for the LiveKit service
Voice services list with the Manage button highlighted for the LiveKit service
Step 4: Open Connections > SIP Incoming Trunk.
Service Configuration page with SIP Incoming Trunk selected and Add New highlighted.
Service Configuration page with SIP Incoming Trunk selected and Add New highlighted.
Step 5: Select Add New.
Step 6: Enter these settings:
Add New Incoming Trunk dialog with the LiveKit name and primary IP address entered
Add New Incoming Trunk dialog with the LiveKit name and primary IP address entered
2 of 2 rows
NameA clear name such as LiveKit Incoming
Primary IP AddressThe SIP URI shown in your own LiveKit project
Step 7: Save the new SIP Incoming Trunk.
Use the value from your own project. Do not copy another project's address.

Route the assigned number to LiveKit

Navigate: Your Voice Service's Assigned DID page in the Atomic portal.
Step 1: Open the Voice Service and go to Assigned DID.
Service Configuration page with Connections open and the Assigned DID tab visible
Service Configuration page with Connections open and the Assigned DID tab visible
Step 2: Find your assigned number and select Manage.
Number Inventory with the assigned LiveKit number and Manage button highlighted
Number Inventory with the assigned LiveKit number and Manage button highlighted
Step 3: On Edit DID, enter these settings:
Edit DID dialog with the LiveKIT label, incoming connection, +E.164 format, and Forward DID in URI…
Edit DID dialog with the LiveKIT label, incoming connection, +E.164 format, and Forward DID in URI…
5 of 5 rows
DID LabelA clear label such as LiveKit
Incoming ConnectionThe LiveKit Incoming connection created above
CLI Translation RuleLeave blank
Number Format+E.164
Forward DID in URIEnabled
Step 4: Select Save.

Verify inbound calling

Step 1: Call the assigned Atom number from an external phone.
Step 2: In LiveKit, open Telephony > Calls and confirm that the call appears.
LiveKit Calls page listing inbound calls, with an active call in the top row
LiveKit Calls page listing inbound calls, with an active call in the top row
Step 3: Confirm that the selected AI agent joins the room and answers.
LiveKit call details page showing an active inbound call and its SIP information
LiveKit call details page showing an active inbound call and its SIP information
Step 4: Check that you can hear the agent and that the agent can hear you.
If the call does not reach the agent, check that:
  • The assigned DID uses the new LiveKit incoming connection.
  • The number on the LiveKit inbound trunk matches the assigned Atom number.
  • Allowed addresses is 52.65.130.216/32.
  • Number Format is +E.164 and Forward DID in URI is enabled.
  • The dispatch rule selects the correct inbound trunk and AI agent.

Configure outbound calling

Set the Atom SIP endpoint credentials

Navigate: Services > Voice > Manage > Connections > SIP End Point in the Atomic portal.
Step 1: Open Services > Voice.
Step 2: Manage the Voice Service created for LiveKit.
Step 3: Open Connections > SIP End Point.
SIP End Point settings with the SIP Account value to use as the LiveKit username
SIP End Point settings with the SIP Account value to use as the LiveKit username
Step 4: Record the SIP Account. You will use it as the LiveKit username.
Step 5: Set a new VOIP Password and enter it again under Retype VOIP Password.
Step 6: Store the credentials securely and select Update.

Create an outbound trunk in LiveKit

Navigate: Telephony > SIP trunks in LiveKit.
Step 1: Open Telephony > SIP trunks.
Step 2: Select Create new trunk > Outbound trunk.
LiveKit SIP trunks page with the Create new trunk menu open and Outbound trunk highlighted.
LiveKit SIP trunks page with the Create new trunk menu open and Outbound trunk highlighted.
Step 3: Enter these settings:
LiveKit outbound trunk form with name, address, transport, and Atom numbers entered
LiveKit outbound trunk form with name, address, transport, and Atom numbers entered
4 of 4 rows
Trunk nameA clear name such as Atomic Outbound
Addresssip3.atomcomm.com
TransportAuto
NumbersYour assigned Atom number in +E.164 format
Step 4: Expand Optional settings.
Step 5: Enter these settings:
Outbound trunk setup with media encryption, username, and password settings highlighted
Outbound trunk setup with media encryption, username, and password settings highlighted
3 of 3 rows
Media encryption (SRTP)Media encryption disabled
UsernameThe Atom SIP Account recorded above
PasswordThe Atom VOIP Password set above
Step 6: Select Create.
For the outbound trunk's Numbers, include the leading + and country code. Use your own assigned Atom number.

Set up the LiveKit CLI

LiveKit can place outbound calls through the CLI, server API or your application. The following Windows PowerShell procedure uses the CLI to start the agent first and then place a manual call.
Step 1: If the CLI is not installed, open PowerShell and run:
powershell
winget install LiveKit.LiveKitCLI
Step 2: Connect the CLI to LiveKit Cloud:
powershell
lk cloud auth
Step 3: List the available projects:
powershell
lk project list
Step 4: Set the project to use. Replace YOUR_PROJECT_NAME with the correct project name:
powershell
lk project set-default "YOUR_PROJECT_NAME"

Find the outbound trunk ID

Step 1: List the outbound trunks:
powershell
lk sip outbound list
Step 2: Copy the ID of the Atom outbound trunk.

Dispatch the AI agent

Step 1: Choose a unique room name for this call. The commands below use atomic-outbound-001; use the same room name throughout the call procedure.
Step 2: Start the deployed agent in that room. Replace YOUR_AGENT_NAME with the deployed agent's name:
powershell
lk dispatch create --room atomic-outbound-001 --agent-name "YOUR_AGENT_NAME"
Production agent dispatch: Leave the deployment unset for this configuration. Do not add --deployment production.
Step 3: Check the room participants and confirm that the AI agent is active before placing the call:
powershell
lk room participants list atomic-outbound-001

Place the outbound call

Step 1: Replace the three placeholder values below with your trunk ID, the destination number you control and your assigned Atom caller ID. Run these lines in the same PowerShell session:
powershell
$OutboundTrunkId = "YOUR_OUTBOUND_TRUNK_ID"
$DestinationNumber = "DESTINATION_COUNTRY_CODE_AND_NUMBER"
$CallerId = "+YOUR_ATOM_NUMBER_WITH_COUNTRY_CODE"
Use these formats:
4 of 4 rows
$OutboundTrunkIdThe ID copied from the Atom outbound trunk
$DestinationNumberCountry code and number without a leading +
$CallerIdYour assigned Atom number with a leading + and country code
Room nameThe same room used to dispatch the agent
Step 2: Create the telephone participant in the same room:
powershell
lk sip participant create --trunk $OutboundTrunkId --call $DestinationNumber --number $CallerId --room atomic-outbound-001 --identity outbound-customer --name "Outbound customer" --wait --timeout 1m20s
Use a new room name for each call, such as atomic-outbound-002. Change it in both the agent-dispatch and telephone-participant commands.

Verify the outbound call

Step 1: While the call is connected, check the room participants:
powershell
lk room participants list atomic-outbound-001
The room should contain the active AI agent and telephone participant with audio tracks.
Step 2: Open Telephony > Calls in LiveKit and confirm the outbound call appears.
Step 3: Check that the person on the phone can hear the agent and that the agent can hear them.
If the phone rings but the call is silent, check that the AI agent was active before the telephone participant was created. Keep the outbound trunk's Transport set to Auto.

Configuration summary

11 of 11 rows
LiveKit inbound numberAssigned Atom number
Inbound allowed address52.65.130.216/32
Inbound dispatch ruleIndividual, with Room prefix blank
Atom DID number format+E.164
Forward DID in URIEnabled
Outbound addresssip3.atomcomm.com
Outbound transportAuto
Outbound caller IDAssigned Atom number in +E.164 format
Outbound destinationCountry code and number without a leading +
Outbound authenticationAtom SIP Account and VOIP Password
Agent dispatchBefore the call, with no --deployment production option