Self-hosted LiveKit SIP + Plivo Zentrunk for outbound calls: is this setup complete?

Hi all,

We’re moving our voice agent’s telephony from LiveKit Cloud SIP to a fully self-hosted setup and want to confirm we’re not missing anything before we build it.

Planned setup (single server for now, Mumbai region):

  • livekit-server [version]
  • Redis (shared between livekit-server and livekit-sip)
  • livekit-sip [version]
  • LiveKit Agents worker [Python/Node, version]
  • Plivo Zentrunk as the SIP trunk, with an Indian Plivo number as caller ID

Outbound flow we’re planning:

  1. Create a Zentrunk outbound trunk in Plivo (auth: [credentials / IP whitelist]).
  2. Create a LiveKit outbound trunk pointing to Plivo’s termination domain.
  3. Use CreateSIPParticipant to place the call and dispatch the agent into the same room.

Questions:

  1. Is livekit-server + Redis + livekit-sip the minimum required, or is there a component we’re missing?
  2. Can a self-hosted livekit-sip connect to LiveKit Cloud rooms, or does it strictly require a self-hosted livekit-server? (We believe the latter because of the shared Redis requirement.)
  3. Any known issues with Plivo Zentrunk specifically: codecs, auth, or SIP headers?
  4. Recommended config to avoid NAT and one-way audio problems on a cloud VM (use_external_ip, RTP port range, etc.)?
  5. Has anyone run outbound calls to Indian numbers this way? Any regulatory or Plivo-side restrictions we should know about?

Thanks!

Hi Aman,

I run a fully self-hosted LiveKit stack for voice agents because running through US cloud instances introduced too much latency.

Here are the answers to your specific questions based on running this in production.

  1. Components: livekit-server, Redis, and livekit-sip are the core requirements. If you plan to record calls or export media, you will also need livekit-egress. For managing trunks, dispatch rules, call logs, and observability without doing everything through the CLI, I run livekitdashboard.com on top of it.

  2. LiveKit Cloud with self-hosted SIP: [Inference] You cannot connect a self-hosted livekit-sip instance directly to LiveKit Cloud. The SIP bridge depends on internal Redis pub/sub and state synchronisation with livekit-server, which LiveKit Cloud does not expose externally. You must host both if you self-host SIP.

  3. Plivo Zentrunk: Stick to G.711 PCMU and PCMA codecs for stability. Use IP whitelisting rather than SIP credentials to avoid SIP registration overhead and authentication failures on high concurrency. Ensure your outbound caller ID strictly matches E.164 format.

  4. NAT and Audio: Set use_external_ip: true in your configuration files for both livekit-server and livekit-sip, or explicitly set nat_1to1_ips to your VM public IP. Open UDP port 5060 for SIP signaling. Open UDP ports 10000 to 20000 for LiveKit SIP RTP traffic, and UDP 7882 for WebRTC traffic. If your cloud security group blocks these UDP ranges, you will get immediate one-way audio or fast drops. The internet is loaded with SIP bots. Very important, so also firewall this properly. I only allow SIP ports 5060 UDP/TCP from SIP provider I use.

  5. India calling: From what I know, and as Indian Telco is very restricted. India has strict TRAI and Department of Telecommunications routing regulations. Outbound calls terminating to Indian numbers require verified sender IDs and compliant routing. Plivo enforces strict business KYC and pre-registration for Indian caller IDs before outbound calls will connect. You also can’t have the server hosted, say, in Australia but have Indian SIP trunks.

Good luck - The time will be well spent when you see the qulity of your agents.