AVOXI - FreePBX SIP Configuration

General Configuration 

The purpose of this guide is to help you setup a basic trunk, inbound route, and outbound route. For further assistance with FreePBX, please consult their wiki located here https://wiki.freepbx.org/display/FPG

Dialplan
We do not require you to send any 00 nor 011 code for international calls, we just need to receive the country code followed by the number, please check the examples below 

To call AVOXI USA Support number 

1-678-631-2280

To Call AVOXI Costa Rica Support number (Costa Rica country code is 506) 

506-2506-4100


Add PJ_SIP Trunk

To do this,

1. Go to Connectivity > Trunks. Click Add Trunk and select "Add SIP (chan_pjsip) Trunk".

2. In the General tab, define the Trunk name (can be anything you want)

3. In the PJSIP settings, change the Authentication to None 

Delete

If you are using Basic Auth (username/password) for your SIP Trunk in your Genius tenant, please set Authentication to "Outbound" and put your username in username and password in secret (auth username if left blank should use the value specified in "username")

Delete

If you are using SIP Header Auth (SIP Header Name + Value), you'll have to define a custom SIP Header in one of the Asterisk config files. Please refer to the FreePBX documentation or reach out to FreePBX support for assistance. Also please note that SIP Header Auth is not as secure as Basic Auth, so we don't recommend using this method standalone)


4. AVOXI Genius does not support SIP registration, so set Registration to None

5. The SIP Server is going to be the DNS Host name located under "Setup Instructions" once you create a SIP Trunk in Genius. Server port is going to be 5060 (or 5061 if you are planning on using TLS signaling)

Delete

If you are using our service for inbound calls only, you may put value "localhost" or some other dummy information that FreePBX allows as this is only used when placing outbound calls.


6. Navigate to the advanced section of the PJSIP trunk and in the Match (Permit) section, please use the IP's specified in our AVOXI Genius IP Whitelist KB article (specifically the section labeled "SIP AVOXI to Customer (Inbound)") for the Data Center you are receiving calls from. To check what Data Center you'd be using for inbound calls, please refer to the Data Center configured for your number(s) and use those IP's.

Delete

For example, if you are receiving calls from our US Data Center, please use "104.196.177.56/32, 104.196.177.203/32". If you are receiving calls from AU/BR/ME/UK Data Center, you can just use this range "199.244.98.0/23".


Delete

The below screenshots have old placeholder information. Do not use "trunk-production-us1.avoxi.com" in SIP server as that's outdated. You need to use the DNS Host name specified in "Setup Instructions" for your SIP Trunk in your Genius tenant. Note that you can use any of the DNS host names specified in the dropdown menu under "Setup Instructions", that's just read-only information. Changing to a different data center and pressing save won't do anything as all of them are active.



The default transport set is UDP. If you prefer TCP connection, you will need to go to Settings > Asterisk SIP Settings > SIP Settings (chan_pjsip). Under Transports, you can enable TCP and TLS (we do not use ws or wss).

If you are setting up TLS with SRTP on FreePBX, please use this guide to do so: https://wiki.freepbx.org/display/phon/tls+and+srtp. Also refer to the Genius SIP Trunking for Outbound Termination guide for the files necessary from us: https://support.avoxi.com/153319-sip-configuration-guides/configuring-sip-trunks-in-genius#downloading-sip-uri-tls-certificate-4


Add Inbound Routes

Here is where you define what you want calls inbound to your PBX to do. This can be found via Connectivity > Inbound Routes. If you have multiple DIDs and need them to do specific things, you'd define a single DID in the DID Number section per Inbound Route.



Add Outbound Routes

Here is where you define what you want calls initiated by your extensions to do. This is useful for if you have multiple trunks going to different providers or you want certain calls recorded locally (Additional Settings > Call Recording) or if you want calls placed intra-company to use different Caller ID settings.


For info on setting up SIP URIs and SIP Trunks in Genius, refer to the below section:

https://support.avoxi.com/153319-sip-configuration-guides

Give feedback about this article

Was this article helpful?

Have more questions? Submit a request

Updated:

December 30th, 2024

Author:

Louise Ross

Updated By:

Max Germain

KB ID:

843267

Page Views:

4633

Tags:

freepbx voip, sip config

Can’t find what you’re looking for?

Contact our award-winning customer care team.