SIP is currently in Developer Preview.
Inbound calls
Inbound calls are handled by SIP Trunk and SIP Dispatch Rule. See documentation for these resources for examples how to create them and the options available.
Outbound calling
To make outbound calls with SIP Service, create SIP Participant with CreateSIPParticipant API. It returns an SIPParticipantInfo
object that describes the created SIPParticipant. These parameters can also be queried at any time using the ListSIPParticipant
API.
Outbound calling requires at least one SIP Trunk with outbound_address
and outbound_number
set. For most SIP Trunk Providers the authentication credentials must also be set with outbound_user
and outbound_password
.
Create a file at sipParticipant.json
with the following contents:
{"sipTrunkId": "<your-trunk-id>","sipCallTo": "<phone-number-to-dial>","roomName": "test-call","participantIdentity": "Test call"}
Then create the SIP Participant using livekit-cli:
export LIVEKIT_URL=<your LiveKit server URL>export LIVEKIT_API_KEY=<your API Key>export LIVEKIT_API_SECRET=<your API Secret>livekit-cli create-sip-participant --request sipParticipant.json