I found this great guide to setting up Twilio with Unfi Talk here
here is the TLDR:
- Get an Twilio Sip trunk setup witih a number attached
- when setting up your SIP domain be sure to use the closest regional DNS name to your location
- Setup Dynamic DNS on your Unfi setup in this example: home.example.com
- create an Origination Connection Policy use
- on unfi talk enable "Create Static Signaling Port" and add a port forward rule for tcp/udp 6767 to your unfi controller's IP.
- add a custom sip provider, with the following fields: proxy, username, password, register, transport, dtmf-type.
- Set the following values for those fields
8. proxy: mydomain.sip.twilio.com OR the clostest local access point.
9. username: the username you set in the SIP credentials.
10. password: The password you set in the SIP credentials.
11. register: false
12. transport: tcp
13. dtmf-type: rfc2833
- Add the following CIDRS (us-west): 126.96.36.199/30 & 188.8.131.52/24 or ones that match your localized access point
- add the numbers that you have attched to the sip trunk, note: the
+12345678910, and yes you should add all the numbers you have bound to the trunk on the twilio console.