new BYO SIP trunk only allows 'outbound'
# support
m
Hey everyone 👋 I’m trying to add a BYO SIP trunk for both inbound and outbound calls using the web GUI, but the setup keeps failing whenever I select “inbound calls.” Outbound-only works fine. Has anyone run into this before or know what could cause it? #siptrunk
v
Most inbound SIP trunk setup failures are caused by not allowlisting Vapi's signaling IPs with your provider. Make sure you add these IPs to your SIP provider's allowlist/firewall:
Copy code
44.229.228.186/32
44.238.177.138/32
After updating, try enabling inbound calls again in the GUI. For more details, see the [SIP Trunking guide](https://docs.vapi.ai/advanced/sip/sip-trunk). Source: - [SIP Trunking](https://docs.vapi.ai/advanced/sip/sip-trunk)
m
IPs are whitelisted
g
What exact documentation process did you follow?
m
I used the Vapi documentation. when i create an SIP trunk with inboundEnabled = true it fails.
❯ curl -X POST "https://api.vapi.ai/credential" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer apikey" \ -d '{ "provider": "byo-sip-trunk", "name": "BYO Trunk", "gateways": [{ "ip": "voip.provider.com", "inboundEnabled": true }], "outboundLeadingPlusEnabled": true, "outboundAuthenticationPlan": { "authUsername": "4700xxxxxx", "authPassword": "password" } }' {"message":"Couldn't validate SIP trunk credential. SIP gateway creation failed.","error":"Bad Request","statusCode":400}%  ~ 
with inboudEnable = false, the SIP trunk is added without problems >> ❯ curl -X POST "https://api.vapi.ai/credential" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer api-key" \ -d '{ "provider": "byo-sip-trunk", "name": "byo Trunk", "gateways": [{ "ip": "voip.provider.nl", "inboundEnabled": false }], "outboundLeadingPlusEnabled": true, "outboundAuthenticationPlan": { "authUsername": "4700xxxxx", "authPassword": "password" } }' {"id":"1a2e4ed9-93a3-4726-9fee-d2ea920d4248","orgId":"b7b3d43f-9fe7-470a-8ff9-e28b4d956034","provider":"byo-sip-trunk","createdAt":"2025-10-21T07:38:06.713Z","updatedAt":"2025-10-21T07:38:06.713Z","gateways":[{"ip":"voip.provider.nl","inboundEnabled":false}],"name":"provider Trunk","outboundAuthenticationPlan":{"authUsername":"47000xxxxx"},"outboundLeadingPlusEnabled":true}%
g
@martyvandeveerdonk Alright try making use of the zadarma sip trunking to get this done, follow through the whole step and substitute zadarmi with your own sip provider
c
Hi, to configure the SIP Trunk, please follow the documentation for whitelisting the IP addresses: Then use this template as a guide to configuring both inbound and outbound gateways. The inbound gateway will need a static IP address and the outbound gateway will use the resolved domain name using UDP protocol. You cannot configure one gateway with both inbound and outbound enabled:
Copy code
{
  "provider": "byo-sip-trunk",
  "name": "My SIP Trunk",
  "gateways": [
    {
      "ip": "sip.provider.com",
      "port": 5060,
      "outboundEnabled": true,
      "inboundEnabled": false,
      "outboundProtocol": "udp"
    },
    {
      "ip": "203.0.113.10",
      "port": 5060,
      "outboundEnabled": false,
      "inboundEnabled": true
    }
  ]
}
Once you have configured the SIP trunk, you will receive a value for credentialId. Save that and use it for the next step of assigning the SIP trunk to a phone number, as that is a required value for setting up the phone number. If you encounter any issues with the setup, please feel free to reach out.
m
unfortunally, this keeps failing >> '''curl -X POST https://api.vapi.ai/credential \ -H "Content-Type: application/json" \ -H "Authorization: Bearer private-key" \ -d '{ "provider": "byo-sip-trunk", "name": "Gamma BYO Trunk", "gateways": [{ "ip": "voip.domain.nl", "port": 5060, "inboundEnabled": true, "outboundEnabled": false }] }' {"message":"Couldn't validate SIP trunk credential. SIP gateway creation failed.","error":"Bad Request","statusCode":400}% ❯ ❯ ❯ ❯ ❯ ❯ curl -X POST https://api.vapi.ai/credential \ -H "Content-Type: application/json" \ -H "Authorization: Bearer private_key" \ -d '{ "provider": "byo-sip-trunk", "name": "Gamma BYO Trunk", "gateways": [{ "ip": "voip.domain.nl", "port": 5060, "inboundEnabled": true, "outboundEnabled": false }], "outboundAuthenticationPlan": { "authUsername": "47000xxx", "authPassword": "password" } }' {"message":"Couldn't validate SIP trunk credential. SIP gateway creation failed.","error":"Bad Request","statusCode":400}% ❯'''
2 Views