Can VAPI reject my custom SIP ?
# support
h
I inputed my SIP credential in External Provide Keys. And I integrated it in BYO SIP Trunk Number But it gets "reject" if I make a call to DID number
v
Yes, Vapi can reject your custom SIP connection if the SIP credentials in External Provider Keys are missing, incorrect, or if your SIP client fails to respond to authentication challenges. Double-check that your credentials (username and password) are correct and that your SIP provider responds properly to the 401 challenge. For example, your payload for creating a SIP trunk credential should look like:
Copy code
json
{
  "provider": "byo-sip-trunk",
  "name": "My SIP Trunk",
  "gateways": [{ "ip": "your.sip.provider.ip", "port": 5060 }],
  "outboundAuthenticationPlan": {
    "authUsername": "your_outbound_username",
    "authPassword": "your_outbound_password"
  }
}
Make sure your configuration matches your provider's requirements and test the connection again. Sources: - [Discord documentation on SIP rejection and configuration](https://discord.com/channels/1211482211119796234/1334238882660618250) - [Vapi API documentation for SIP trunk integration](https://docs.vapi.ai/advanced/sip/telnyx)
h
We inputted SIP credential in "External Provide Keys". Then, we created
phone number
in "Phone numbers" -> "Created Phone number" -> "BYO SIP Trunk Number" We inputted this. https://cdn.discordapp.com/attachments/1372352679745028126/1372428391650820136/0.png?ex=6826bd0b&is=68256b8b&hm=3846c6bceb4e3267e4f6051dde85bf8e0a6f65db9226fefe805490a86eab8305&
Sip Credential is from 2600hz.com We created SIP device here. SIP user name: 7998 SIP password: ******** Realm: hvjmg6s.se.vsrns.com DID phone number is also from 2600hz.com +1 (530) 364 0090 We inputted this number in "BYO Sip Trunk number" section. But when we make a call to this number, call is rejected. In the call log in 2600hz.com, it is marked as "rejected". āœ… One of my doubt is "**Is it ok to use Realm as Domain ?**" We appended error log from 2600hz.com I would be grateful if you can tell me what did wrong.
a
Hey, Could you please schedule a brief call at your convenience so we can discuss this matter in detail? Kindly use the following link to book a suitable time: .
n
@Shubham Bajaj The problem above is exhibited by improper INVITE dialog initation, from the VAPI side as I see it. Pay attention to the first rejection from the remote side, which contains the realm as:
sip.vapi.ai
- which is really odd, as it should have been
hvjmg6s.se.vsrns.com
- this potentially means that VAPI sends the outbound invite with a username that isn't formatted correctly. Also, the last error says clearly:
"X-Reason: Invalid credentials"
, which means that the combination of
realm
and the
authorization
challenge don't correlate to their database scheme - which makes sesne, as
sip.vapi.ai
isn't part of their SIP Domains.
h
So, what should I do next ? @Nir S (CEO/Founder @Cloudonix)
Hi, @Nir S (CEO/Founder @Cloudonix)
n
Driving
h
Hello, can you help me ?
n
Well, we can try connecting it via Cloudonix, that will work 100%. Would you like to try that?
h
Yes, I already signed up
How to use your platform ?
Hi, @Nir S (CEO/Founder @Cloudonix)
n
@Hans sorry for not responding, we had a death in the family so was totally taken with it today. I'll be back online on Sunday and I'll be happy to assist.
h
Omg, my Condolences šŸ™ See you on Sunday
a
checking if this is resolved/solved for you?