Intermitent Issue with Twilio incoming Calls

VitalPBX Community Support General Discussion Intermitent Issue with Twilio incoming Calls

  • Post


    I have a Twilio trunk setted as per your documentations and blogs articles. Incoming calls works fine, I already set the Allow Guest Calls to true, and after some tries the incoming call fail and sometimes is Declined with 603 error, sometimes says is Unauthorized and sometimes works fine

Viewing 2 replies - 1 through 2 (of 2 total)
  • Replies

    Twilio use a different IP address for Incoming call, I recommend you to use PJSIP to configure Twilio trunks.

    If you use SIP, you must create a trunk for each IP address.

    This is the list of IP Address for Incoming calls of the different regions:


    With a VitalPBX PJSIP trunk configured against Twilio using Twilio Access Control List only (not Credential List), along with a PJSIP trunk Match list comprised of the Twilio signaling and media gateways, am able to make outbound calls okay, but none of the inbound works. The only way to get the inbound to work was to create a VitalPBX SIP trunk for each Twilio signaling gateway with VitalPBX settings such as:

    Device for Outgoing Calls (Peer)
    Local Username: twilio-va-0
    Remote Host:
    Insecure: Port,Invite
    Quality: Yes

    And the trunks will look like via ‘sip show peers’:

    twilio-va-0 No No 5060 OK (1 ms) Twilio-VA-0 
    twilio-va-1 No No 5060 OK (1 ms) Twilio-VA-1
    twilio-va-2 No No 5060 OK (1 ms) Twilio-VA-2
    twilio-va-3 No No 5060 OK (1 ms) Twilio-VA-3

    With this, cannot make outbound calls with the Twilio SIP trunks (‘Forbidden’).

    So with this setup I create an Outbound Route to use the Twilio PJSIP trunk, and all of the inbound will be handled via the other SIP trunks configured to each and every Twilio signaling gateway.

    It seems to me this should not be necessary. I don’t know the ramifications of having literally dozens of SIP registrations against Twilio – local system resources, getting blacklisted, or otherwise. This practice or method simply isn’t necessary on other competitive Asterisk-based products.¬†

    Has anyone been able to get inbound and outbound to work for a single VitalPBX PJSIP Twilio trunk using Twilio ACL and/or Credentials?


Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.