- Create the trunk on Bolna with your provider’s gateway details and authentication credentials
- Add your phone numbers (DIDs) so Bolna knows which numbers to route through this trunk
SIP Trunking is currently in Beta. Contact enterprise@bolna.ai or schedule a call for access.
Prerequisites
Before you begin, make sure you have:- A SIP trunk already created on your provider (Plivo guide or Twilio guide)
- Your provider gateway address (e.g.,
XXXX.zt.plivo.comfor Plivo orbolna-trunk.pstn.twilio.comfor Twilio) - Your authentication credentials: username/password for
userpassauth, or provider IP ranges forip-basedauth - Your Bolna API key from the Bolna Dashboard
- Your DID phone numbers that you purchased from your provider
Step 1: Create the Trunk on Bolna
Use the Create SIP Trunk API to register your trunk. The exact payload depends on your provider and authentication method. Choose the example that matches your setup:- IP-Based Authentication (e.g., Plivo, Telnyx)
- Username/Password Authentication (e.g., Twilio, Zadarma, Vonage)
With IP-based auth, your provider identifies Bolna by its source IP address. You provide your provider’s IP ranges so Bolna can verify that incoming SIP requests are legitimate.
Step 2: Add Phone Numbers
Register the DID phone numbers you have already purchased on your SIP provider (from Plivo or Twilio). Bolna does not provision numbers, it needs to know which of your provider numbers to route through this trunk for inbound matching and outbound caller ID. Use the Add Phone Number API for each number:Adding Multiple Numbers
Repeat the API call for each DID number you want to add. Each number receives its own uniqueid:
Phone number format: Bolna stores the number exactly as you provide it and performs flexible matching (with and without the
+ prefix) for inbound calls. Use a consistent format across your configuration.Step 3: Verify Your Trunk
After creating the trunk and adding numbers, verify that everything is configured correctly. Use the Get SIP Trunk API to check your trunk:| Field | Expected Value | What It Means |
|---|---|---|
is_active | true | Trunk is active and ready for calls |
inbound_enabled | true | Trunk can receive inbound calls |
gateways | Your gateway address | Gateway is correctly configured |
phone_numbers | Your added numbers | All DIDs are registered |
Field Reference
Here is a complete reference of all fields you can use when creating a trunk:| Field | Type | Required | Default | Description |
|---|---|---|---|---|
name | string | Yes | Human-readable label for the trunk. Must be unique. | |
provider | string | Yes | SIP provider: "twilio", "plivo", "zadarma", "telnyx", "vonage", "custom" | |
description | string | No | null | Optional description for your internal reference |
auth_type | string | Yes | "userpass" (username/password) or "ip-based" | |
auth_username | string | If userpass | null | SIP username for authentication |
auth_password | string | If userpass | null | SIP password for authentication |
gateways | array | Yes | At least one gateway with gateway_address (required), port (default 5060), priority (default 1) | |
ip_identifiers | array | If ip-based | [] | List of { "ip_address": "..." } objects in CIDR notation |
allow | string | No | "ulaw,alaw" | Comma-separated codecs to allow. Always include ulaw. |
disallow | string | No | "all" | Comma-separated codecs to block |
inbound_enabled | boolean | No | false | Set to true to receive inbound calls |
outbound_leading_plus_enabled | boolean | No | true | Prepend + to outbound dialed numbers (required by Twilio) |
rtp_symmetric | boolean | No | true | Symmetric RTP for NAT traversal. Keep as true. |
force_rport | boolean | No | true | Force responses to source port. Keep as true. |
qualify_frequency | integer | No | 60 | SIP OPTIONS keepalive ping interval in seconds. Set to 0 to disable. |
Next Steps
Your trunk is registered and phone numbers are added. Now configure how calls are handled:Receive Inbound Calls
Map your phone numbers to AI agents so they answer incoming calls
Make Outbound Calls
Place outbound calls from your trunk numbers using AI agents

