Using Voxbone with 3CX

We believe setting up business communications should be a straightforward, painless process. That’s why we build our SIP services to play well with whichever communications platform you might use – whether it’s hardware-based or hosted in the cloud; built internally or bought from a third-party vendor.

In effect, this enables you to Bring Your Own Carrier (us!) to any other communications platform you use. Why is this better than paying for a bundled service from one provider? Because it allows you to benefit from Voxbone’s fully compliant, reliable voice infrastructure, and the improved connectivity and scalability of our network, while continuing to use your existing apps. It’s a win-win for you.

This guide shows you how to bring your Voxbone numbers to 3CX. It’s easy to connect numbers from your Voxbone account to the 3CX platform, and enjoy both inbound and outbound calling services with a simple configuration.

What you’ll need to get started:

  1. A registered Voxbone account with assigned numbers. (Create your account here)
  2. A working deployment of 3CX (Create it here)

Note: On both platforms, a free-trial account is enough to get started!

How it Works

voxbone + 3cx

When a call is received on our platform, we deliver this call to your designated SIP interface through voice URIs. Behind the scenes, we take care of complex things like least-cost routing, finding the best provider and optimizing for maximum call quality. To connect your Voxbone numbers and receive and place calls on your 3CX PBX platform, we need to establish a SIP interface between our platform and theirs. This can be done in four steps:

  1. Create a Generic VoIP Provider to allow signalling between Voxbone and your 3CX instance
  2. Assign any Voxbone DIDs you’d like to use on 3CX to your VoIP Provider configuration
  3. Assign a voice URI to a DID and place a call
  4. Place a call from 3CX Client to test outbound calling

Import VoIP Provider settings for Voxbone

You can easily import an XML file containing all the configuration options explained in detail below. With this option, you can simply import, add in your credentials and good to go! To do so:

  1. Log in to your 3CX console
  2. Go to “SIP Trunks” view via the side navigation
  3. Click “Import Provider”
  4. Upload the 3CX provider XML file for Voxbone: Download here.
  5. Add your SIP Digest credentials
  6. Set inbound routing by “Route calls to” section on “General” tab
  7. Create at least one Outbound Rule that uses the newly configured trunk

Configure Voxbone as VoIP Provider on 3CX

SIP Trunk configurations on 3CX platform are quite simple. To establish connectivity, we need to specify inbound and outbound signalling FQDNs for Voxbone, provide authentication details, add DIDs we want to use, and modify some headers.

Create new VoIP Provider

  1. Log in to your 3CX Console
  2. In the console, go to “SIP Trunks” from the side navigation
  3. To add Voxbone as a Generic VoIP Provider, click on “Add SIP Trunk” add sip trunks
  4. Select “Generic” from the country list and “Generic VoIP Provider” in the providers list. Finally, enter a “Main Trunk No”. This can be an extension, a phone number in E164 format that you’d like to use for the trunk, or any number. new sip trunk provider
  5. Once you click “OK”, you will be taken to the VoIP Provider details. Here, we’ll configure the FQDNs for inbound and outbound SIP traffic between our 3CX instance and Voxbone.

Configure Trunk Details

  1. Under “General” tab, you can find the Trunk Details. First, rename the Trunk to “Voxbone” for clarity.
  2. Set “Registrar/Server/Gateway Hostname or IP” to be “voxbone.com” as all our PoP servers are subdomained. This will ensure inbound traffic from all Voxbone PoPs. Leave port as 5060. Optionally, you can specify one of the interconnect IP addresses of ours if you only have inbound traffic from one PoP/location.
  3. Set “Outbound Proxy” to be “voxout.voxbone.com”. Your call request will be routed to the closest PoP based on location. Optionally, you can use our anycast IP, which would achieve the same result, “81.201.89.110”
  4. Finally, set maximum concurrent calls you want to allow on this trunk. This is how your “Trunk Details” should look: voxbone voice uri

Configure Authentication for Outbound Calling

We support two ways of authentication for outbound calling :

  • SIP Digest (preferred) : Standard digest authentication over SIP. Credentials can be retrieved on Voxbone portal on Configure > Configure Outbound Voice
  • IP-based : If you’re interconnected behind a VPN, you can contact your account manager to have your platform IPs whitelisted

Here’s how you can configure authentication on your Voxbone trunk:

  1. For either authentication option, select “Do not require – IP Based” for “Type of Authentication”
  2. If you’re using SIP Digest, enter your digest username and password generated from Voxbone portal. This can be done by logging in to the portal and generation of new credentials on Configure > Configure Outbound Voice authentication

Add Voxbone DIDs to be used on 3CX

In order to assign numbers you have from Voxbone to your 3CX users, you can add them to your newly configured trunk, and then configure them for inbound calls to users and outbound Caller IDs. As DIDs are added to your trunk, they will be available under “Extensions” to be assigned to 3CX users. To ensure the trunk works, add at least one DID from your Voxbone account for testing.

Note: To test outbound calling, make sure the number you want to use has “Voxout International” and/or “Voxout National” feature(s) enabled. Similarly, it’s useful to double-check the inbound and outbound channels on the DIDs to ensure they match with the maximum concurrent calls specified for 3CX trunk in the previous step.

To assign Voxbone DIDs to your 3CX trunk:

  1. Go to the “DIDs” tab on your VoIP Provider/SIP Trunk management page on 3CX console
  2. Click “Add Single DID”
  3. Enter the DID number from your Voxbone account in E164 format, with “+” prefix did groups

Setup Calling Options

Under “Options” tab, you can enable/disable calling through the trunk. To setup a bi-directional Voxbone Trunk, enable all directions and disable video calling. Optionally, you can edit the list of codecs supported and their preference/priority.

Note: Make sure the codec configuration on 3CX trunk is either the same or a subset of codecs configured on the DID on Voxbone portal (Configure > Configure DIDs)

call options

If your PBX is behind NAT, please ensure that the following options are set, and your Public IP is listed in the specified fields. If you are unsure if your PBX is behind NAT, please consult your network administrator. If your ISP is providing dynamic IP, you will need to manually update these fields if your IP changes in the future. Failure to update the IP will result in no inbound audio on calls. For this configuration, go to “Advanced” section under “Options” tab and

  • Check “Put Public IP in SIP VIA Header”​
  • Select which IP to use in ‘Contact’ (SIP) and ‘Connection'(SDP) fields​ via selecting “Use This IP Address” in the drop-down list of options

Inbound SIP Parameters

The SIP INVITEs sent from Voxbone to 3CX would have the caller source in the “From” header and the “Host” part would have the corresponding IP of the Voxbone PoP handling the incoming call. To ensure traffic from all Voxbone PoPs are routed correctly in 3CX platform under “Inbound Parameters” tab:

  1. Enable “Caller Source Identification”
  2. Select “From : Host Part” in the first drop-down list
  3. Select “”GWHostPort” gateway/provider host/port” call source identification

Outbound SIP Parameters

In order to ensure outbound calls are routed through the “Outbound Proxy” configured on our trunk, we need to modify some parameters from their default values under “Outbound Parameters” tab:

  1. Request Line URI: Host Part > “OutHostPort” outbound proxy host/port
  2. To: Host Part > “OutHostPort” outbound proxy host/port
  3. The rest of the configurations should remain unchanged. outbound parameters

Creating a Voice URI between Voxbone and 3CX

This is where we set up the SIP interface from Voxbone to 3CX. On our platform, this is done via Voice URIs. Depending on your 3CX setup, you might have different formats of URIs for your users. Generally, SIP URIs are setup in the same formats as emails, “user@domain.com”. If you’re using this format, the domain name can be found under Settings > Network > FQDN on 3CX console. To check which type of URIs are used on your 3CX setup, refer to their documentation on configuring SIP.

Note: To be able to differentiate call routing on 3CX platform, you can use the reserved keyword on our platform “{E164}”, so that we can use the same voice URI for many different numbers and detect what number is called/who’s calling on 3CX. If you’re using this routing, assign the DIDs you assigned to your trunk to individual users on 3CX platform.

  1. Log in to your Voxbone account.
  2. Go to Configure > Configure Voice URIs (or, if you’re logged in, click here). Then click “New” to create a Voice URI routed to your 3CX instance.
  3. Specify the Voice URI as {E164}@(whatever you set as the SIP domain on 3CX). For example: {E164}@voxbone-connect.my3cx.be. When you’re done, your Voice URI should look something like this: create voice uri

Route your Voxbone numbers to 3CX

Now, we need to link one of our numbers to the 3CX Voice URI we just created.

  1. Go to Configure > Configure DIDs or, if you’re logged in, click here.
  2. Use filters to pick a number of your choice to assign for testing and hit “Search”.
  3. Once you’ve picked your number, under the Configuration menu, go to the “Voice” tab and click “Voice URI”. Make sure to pick at least g.729 and g.711 codecs to prevent any SDP or media-related errors. voice uri
  4. Select the Voice URI you just created from the previous step from the modal window.
  5. Hit “Apply” and “Continue”, then finally, “Confirm”.
  6. All set! Now place a call to the number you are using for testing. It should reach your 3CX server.

E164 Processing

Voxbone is expecting the proper E164 numbering format to be used for calls carried through our platform, with a preceding “+” sign. This can also be managed via “Outbound Rules” on 3CX platform where you can prepend the “+” sign to the dialled number.

Overall, we recommend always using the standard format with the “+” sign both for DIDs assigned to your 3CX SIP Trunk for Voxbone and whenever dialling an international number. To ensure E164 numbers are processed properly, go to Settings > E164 Processing on 3CX console and disable E164 Processing.

e164 settings

Testing inbound calls

Any calls placed to the numbers associated with your 3CX URI are now delivered by Voxbone to 3CX. If you used the {E164} keyword, your 3CX app should see them as calls received to URI (called Voxbone DID)@(3CX FQDN Domain). For example in this tutorial, if the Voxbone number “3228080000” is linked to {E164}@voxbone-connect.my3cx.be, when a call is placed, 3CX trunk would see an incoming call to 3228080000@voxbone-connect.my3cx.be. Now, based on the SIP headers, you can keep using your existing Call Queues, Ring Groups or Call Flow Apps without changing anything, but use Voxbone as the delivery platform.

Troubleshooting

If inbound calls can’t get connected to 3CX, you will see “Channel unavailable” as call status on our CDRs. This means we couldn’t deliver to the Voice URI configured, which might be due to:

You can always check your event log for more information on call issues by going to Dashboard > Event Log.

Testing Outbound Calls

To test outbound calls via Voxbone through 3CX, make sure you have at least one Outbound Rule configured to use your Voxbone trunk. The most basic rule would be with the + sign or your designated prefix for outbound calls, such as “9” or “0”. Refer to the 3CX guide for more on this (Outbound Rules on 3CX platform). Here’s how our test rules look:

outbound rules

Testing International/National Calls

After assigning a DID from your Trunk to an Extension, just dial a national or international number from your 3CX Client.

Testing Emergency Calls

As testing actual calls to emergency services is impractical, we have a dedicated 3-digit number you can dial to ensure your setup works fine for real emergency calls. To test it, add an Outbound Rule with 3-digit dials, or a specific one with “777” as the value for “Calls starting with prefix”. Then, make an outbound call from your 3CX client to number 777, which will connect you to an echo service. Once you validate two-way media, all emergency calls will work fine, as long as DIDs are enabled for the service on Voxbone platform.

Troubleshooting

Issues with outbound calls can be due to several reasons:

  • Getting “Forbidden”/”Service Unavailable” on 3CX client: Make sure your account is enabled to use our outbound service and verify your authentication credentials. Once that’s done, check if the caller ID assigned to your 3CX user/trunk is enabled on Voxbone for outbound calling (Voxbone Portal > Configure > Configure DIDs)
  • Getting “Not Found” on 3CX client: Make sure the dialled number/pattern matches at least one of the Outbound Rules configured.
  • Getting “Declined” on 3CX Client: If you’re testing on a brand new setup of 3CX, it’s likely that international calls are disabled on the PBX. By default, only the country of location selected is enabled to be dialled. To check if the destination you’re trying to dial from 3CX client is enabled;Log in to your 3CX ConsoleOn the side navigation bar, click Security > Security SettingsUnder “Allowed Country Codes” tab, make sure the destination you’re trying to dial is enabled
  1. Log in to your 3CX Console
  2. On the side navigation bar, click Security > Security Settings
  3. Under “Allowed Country Codes” tab, make sure the destination you’re trying to dial is enabled security settings

You can always check your event log for more information on call issues by going to Dashboard > Event Log.

Support & further issues

If you are still having issues with connecting Voxbone to 3CX after following through the troubleshooting tips above;

  1. First check if your calls are reaching Voxbone by looking at your Call History (Log in to Voxbone Portal > Account > Call History)
  2. If you see a call record with Voxbone with an error message, contact our support team by creating a ticket (Log in to Voxbone Portal > Account > Support > New Support Ticket)
  3. If you don’t see a call record with Voxbone, this means the call was declined/rejected by your 3CX instance. In this case, contact 3CX for support.

To help with troubleshooting, it’s always handy to share the SIP trace of the failed call you’re referring to. Follow this guide on how to analyze SIP traces with 3CX.

Click here for the XML file