I am trying to trigger a make outbound call using Twilio sip trunk. Done Tried multiple options to sort the issue every time I am making changes giving me a different error.
Getting below error:
Unable to create PJSIP channel - endpoint
Unable to create channel of type 'PJSIP' (cause 3 - No route to destination)
Error from logs
-- Executing [+1234567890@twlext:2] Dial("PJSIP/User1-00000000", "PJSIP/+1234567890@twl") in new stack
[2020-12-02 10:57:53] ERROR[26856]: chan_pjsip.c:2699 request: Unable to create PJSIP channel - endpoint 'twl' was not found
[2020-12-02 10:57:53] WARNING[26921][C-00000001]: app_dial.c:2576 dial_exec_full: Unable to create channel of type 'PJSIP' (cause 3 - No route to destination)
-- No devices or endpoints to dial (technology/resource)
-- Executing [+1234567890@twlext:3] Answer("PJSIP/User1-00000000", "") in new stack
[2020-12-02 10:57:53] ERROR[26856]: pjproject: <?>: icess0x7f67b894b038 ...Error sending STUN request: Operation not permitted
[2020-12-02 10:57:53] ERROR[26871]: pjproject: <?>: icess0x7f67b894b038 ..Error sending STUN request: Operation not permitted
-- Executing [+1234567890@twlext:4] Hangup("PJSIP/User1-00000000", "") in new stack
== Spawn extension (twlext, +1234567890, 4) exited non-zero on 'PJSIP/User1-00000000'
[2020-12-02 11:02:47] WARNING[26870]: res_stun_monitor.c:138 stun_monitor_request: STUN poll failed. Re-evaluating STUN server address
Here is my pjsip.conf file
[twl]
type=aor
max_contacts=10
qualify_frequency=120
remove_existing=yes
contact=sip:NUMBER@SUB_DOMAIN.pstn.twilio.com
[twl]
type=endpoint
context=twl
username=USERNAME
secret=PASSWORD
host=SUB_DOMAIN.pstn.twilio.com
canreinvite=no
disallow=all
allow=ulaw
insecure=port,invite
fromdomain=SUB_DOMAIN.pstn.twilio.com
context=from-trunk
callerid="NAME" <+REGISTER_NUMBER>
[twl]
type=identify
endpoint=twl
match=SUB_DOMAIN.pstn.twilio.com
match=sip.twilio.com