DIDforSale’s SIP Trunking Interconnection Guides

Businesses have been using DIDforSale’s SIP Trunks with following PBX’s:-

Assuming that you have one of the above PBX’s we have setup following guidelines for you to create connection between DIDforSale and your PBX.


Back to the Top

3CX

To download pdf please click » 3CX Interconnection Guide

For configuring our service with 3cx, you need to create three SIP trunks. Two for incoming calls and one trunk for outgoing.

To create a sip trunk, click on SIP Trunks. Add the details as shown in below figure. Select country as Generic and provider as Generic sip trunk.

1_3CX Phone System Management Console instance1

Click on Next and in the next window, add SIP server hostname or IP as 209.216.2.211 and SIP Server port as 5060 as shown in the below figure

 

2_3CX Phone System Management Console instance1

Click Next, In the account details window, add external number as your DID number as shown in figure

3_3CX Phone System Management Console instance1

And click Next

From this menu, select the destination to which the DID number should be forwarded in your 3cx system as show in in below figure. You can send the calls to an extension, queues, ivr, voicemail, fax or to an external number.

4_3CX Phone System Management Console instance1

Click on Next and the next window is for configuring outgoing routes for this trunk. You ca n skip this step as this trunk is only used for incoming calls.

Create one more similar trunk by replacing the server hostname or IP in figure 2 with 209.216.15.70. All other settings are similar to the first trunk.

After creating the two trunks, try making a call to the DID number and the calls will reach to the destination in your 3cx to which the number is configured.

Create outbound trunks

For making outgoing calls from your 3cx system through us, a sip trunk should be created with the ip address 209.216.2.212

For creating the outbound sip trunk, go to SIP Trunk option in your 3cx system and create a new sip trunk

Select country and provider as generic and Generic sip trunk respectively as shown in below figure.

5_3CX Phone System Management Console instance1

Click on next and add the SIP Server Hostname or IP as 209.216.2.212 and SIP Server Port as 5060 as shown in below figure

6_3CX Phone System Management Console instance1

You can skip the inbound rule section as this trunk is only used for outgoing calls.

From the outbound rule section, add the details as shown in below figure. This will allow you to dial US calls with prefix 1 through our system.

7_3CX Phone System Management Console instance

Click on finish. The new trunk will be active now and you can start making calls through it.

Back to the Top

 

Back to the Top

Asterisk

To download pdf please click » Asterisk_Interconnection_Guide

To create an interconnection between your asterisk server and DIDForSale servers, you need to create 4 trunks in your sip.conf file. Two trunks for incoming calls and two for outgoing calls.

For creating the trunks, open /etc/asterisk/sip.conf file in your favorite editor and add the following trunk details in to it. [didforsale_in1] host=209.216.2.211
type=peer
context=from-trunk
disallow=all
allow=ulaw
nat=yes
canreinvite=yes
insecure=very
dtmfmode=rfc2833
qualify=yes

[didforsale_in2]
host=209.216.15.70
type=peer
context=from-trunk
disallow=all
allow=ulaw
nat=yes
canreinvite=yes
insecure=very
dtmfmode=rfc2833
qualify=yes

[didforsale_out1]
host=209.216.2.212
type=peer
context=from-trunk
disallow=all
allow=ulaw
nat=yes
canreinvite=yes
insecure=very
dtmfmode=rfc2833
qualify=yes

[didforsale_out2]
host=209.216.15.71
type=peer
context=from-trunk
disallow=all
allow=ulaw
nat=yes
canreinvite=yes
insecure=very
dtmfmode=rfc2833
qualify=yes

Now you have to create a dialplan entry to catch all incoming calls coming from DIDForsale. For doing that, open /etc/asterisk/extensions.conf and add the below entries

[from-didforsale]
exten => _X.,1,Noop(Incoming calls from DIDForSale)
same => n,Dial(SIP/1000)
same => n,Hangup

The above dialplan entry catch all calls coming from didforsale and send it to the extension 1000 in your system. You can change that to forward calls to any other extension or ivr on your system.

For making outgoing calls from your system through didforsale, create the below dialplan entry

[outbound]

exten => _X.,1,Dial(SIP/didforsale_out1/${EXTEN})
same => n,Dial(SIP/didforsale_out2/${EXTEN})
same => n,Hangup

Change the context name “outbound” in the above entry to the context name of your extensions.


Back to the Top

Freepbx

To download pdf please click » Freepbx_Interconnection_Guide

Create trunks for Inbound

Step 1: Login to your freepbx admin interface, go to Connectivity à Trunks and select the option Add SIP Trunk. and then give a name for the trunk as didforsale_1 and add the trunk Parameter as shown in below img. Freepbx-create-trunks Copying the parameters here for a clear view host=209.216.2.211 type=peer context=from-trunk disallow=all allow=ulaw nat=yes canreinvite=yes insecure==very dtmfmode=rfc2833 qualify=yes And save the changes

Step 2: Create a second trunk for inbound with trunk name as didforsale_2 and add the trunk Parameters as shown in below img. create-sip-trunks-for-inbound2 Copying the parameters here for a clear view type=peer nat=yes insecure==very host=209.216.15.70 dtmfmode=rfc2833 disallow=all context=from-trunk canreinvite=yes allow=ulaw And save the changes

Creating Outbound Trunk

Go to Connectivity à Trunks and select the option Add SIP Trunk. and then give a name for the trunk as didforsale_out1 and add the trunk Parameter as shown in below img. outbound-trunk1 Copying the parameters here for a clear view type=peer nat=yes insecure==very host=209.216.2.212 dtmfmode=rfc2833 disallow=all context=from-trunk canreinvite=yes allow=ulaw Create a second trunk in the same way with trunk name as didforsale_out2 with the below trunk parameters type=peer nat=yes insecure==very host=209.216.15.71 dtmfmode=rfc2833 disallow=all context=from-trunk canreinvite=yes allow=ulaw And save the changes

Routing Inbound DID

For routing your inbound calls coming on your DID number, click on inbound routes and configure the DID with prefix 1. Toll free numbers needs to be configured without 1. Say your DID is 949 885 9944 then you will configure the DID with 19498859944 in the inbound routes. Delete existing routes for the DID and then reconfigure from scratch. Here is the image for inbound setups add-incoming-route Hope this Document helps. Please contact us if you have any clarification


Back to the Top

Freeswitch

To download pdf please click » Freeswitch_Interconnection_Guide

You need to allow our IPs in your freeswitch server to receive calls from the DID number. For that, go to your freeswitch configuration directory and edit the file acl.conf.xml inside the autoload directory of freeswitch configuration directory. Find the domains section in the configuration file and add our IPs as shown below

<node type=”allow” cidr=”209.216.15.70/28″/>

<node type=”allow” cidr=”209.216.2.211/26″/>

Now you need to add a dialplan entry in your server to catch the incoming calls to the DID number. For that go to your freeswitch configuration directory, then move to dialplan/public directory and add an xml file there with any name with the below contents.

<include>
<extension name=”incoming_did”>
<condition field=”destination_number” expression=”^(13043935064)$”>
<action application=”transfer” data=”1000 XML default”/>
</condition>
</extension>
</include>

NOTE: Replace 13043935064 with your DID number This dialplan will route all incoming calls coming to the did number to extension 1000.

You will need to reload your acl and xml after doing the configuration. For doing that, go to freeswitch cli by using command “fs_cli” and run the commands reloadacl and reloadxml.


Back to the Top

Grandstream PBX

To download pdf please click » Grandstream_PBX_Interconnection_Guide

For Configuring Grandstream PBX with DIDforsale, you need to create four SIP Trunks. Two trunks for incoming calls and two trunks for outgoing. For creating trunks, go to PBX => VoIP Trunks => Create new SIP Trunk. Add the details as shown in below figure trunks Similarly create three more sip trunks with the following IP address 209.216.15.70 209.216.15.71 209.216.2.212 Once all the trunks are added, the page will looks like trunksall Now you need to configure your DID number. For configuring DID number, go to PBX => Inbound Routes => Create New Inbound Rule and add the details as shown in below figure inbound Now configure outbound routes for sending outgoing calls through didforsale. For outbound routes, go to PBX => outbound Routes => Create New Outbound Rule as shown in below figure outbound Select any one of the outgoing trunks in outbound routes. If you want to do a failover, click the option “click to add failover trunk” on the bottom side and select the second outbound trunk here.

 


Back to the Top

GoautoDial

To download pdf please click » GoautoDial_Interconnection_Guide

For configuring our DID number with goautodial, you will have to create two trunks in your system to allow calls from our server. You can do that by going to Admin section in your goautodial and choose carriers. Click on “Add a New Carrier” and add the following parameters

Carrier Name : DIDforsale_in1
Account Entry :
host=209.216.2.211
type=peer
context=from-trunk
disallow=all
allow=ulaw
nat=yes
canreinvite=yes
insecure==very
dtmfmode=rfc2833
Protocol : SIP
Active : Y

Leave other fields as default or blank. Create one more carrier with same options except the host parameter in Account Entry field. Change the host from 209.216.2.211 to 209.216.15.70 in the new carrier.

Now you will have to route the DID number to the extension you want. You can do that by selecting Inbound –> Add a new DID, Add your DID number, and add the extension to where you want to forward the calls coming to DID in the Extension field and submit.


Back to the Top

Zycoo

To download pdf please click » Zycoo_Interconnection_Guide

How to configure ZycooCooVox IPPBX for DIDforSale SIP Trunks

1) Outbound

  • Create a VoIP trunk for outbound calls

Navigate to CooVox IPPBX web menu: Baisc->Trunks
Click “New VoIP Trunk” button to create a VoIP trunk for outbound DIDforSale server.

1_edit_sip_trunk2

In this case DIDforSale authenticates the subscription using IP address, so we can tick “Without Authentication” option for this trunk. If username and password authentication needed, then do not enable this option and fill in the username and password below.

In Advanced Options section, Insecure was “port,invite”, please change it to “very”. And audio codecs please enable ulaw only.

 

  • Check trunk status
    Navigate to web menu: Operator
    On this page you can check the trunk status:
    2_voip_trunks
    If you get both Status and Reachability as green and OK, then you can continue to configure dial rule and dial plan for outbound phone calls through this trunk. If not, then please check the trunk configurations and verify the parameters given by DIDforSale.
  • Dial Rule
    Navigate to web menu: Basic->Outbound Routes->DialRules
    Click “New Dial Rule” to define a dial rule for making outbound calls through DIDforSale VoIP trunk.3_New_Dial_Rule

    Make sure the VoIP trunk is in the Selected Trunks field, and define you custom pattern, for example “4XX.”, which means if you want to make outbound calls through the DIDforSale trunk then you need to dial the numbers with prefix 4. For example, if you want to dial 1234567, then you need to dial 41234567. And at the bottom there’s a line “Delete ____ digits from……”, here you need to strip the one digit prefix before send this number out, so you fill 1 here. If you use 2 digits prefix then fill 2 here.
  • Dial Plan
    To activate this dial rule and let the users be able to make phone calls through this VoIP trunk, you need to enable the dial rule for the dial plan/dial plans.
    Navigagte to web menu: Basic->Outbound Routes->DialPlans
    Click Edit button of the existing dial plan:4_EditCheck the new dial rule just added then the extension users will be able to make outbound calls through DIDforSale trunk.
    If you want some of the users be able to make outbound calls through this trunk, then please click “New DialPlan” to create a new dial plan, and in this dial plan you enable this dial rule. Then navigate to web menu: Basic->Extensions, edit the extension preferences and select the new dial plan for the extensions.5_Edit_Dialplan2

 

2) Inbound

 

  • Add new trunks

DIDforSale requires 2 extra trunks for fully redundant infrastructure, multiple Trunks are used for Load Balancing and Fail-over.
Navigate to CooVox IPPBX web menu: Baisc->Trunks
Add 2 trunks the same way:

6_new_voip_trunk

7_new_voip_trunk

These 2 trunks are for inbound so Outbound CID field can be left blank.

 

  • Configure Inbound Control
    Naviagate to CooVox IPPBX web menu: Inbound Control->Inbound Routes
    Below General tab configure General inbound route for VoIP channels:8_from_voip_chanels
  • Number DIDs
    If you want the inbound calls calling in from different DID numbers been handled separately, then you can configure number DIDs. Click the Number DIDs tab and click New Number DID button to configure:9_number_didsFill in the DID number in DID Number field and select a destination for this DID number then if someone calls this number, the call will go directly to the destinations you configured. For other calls will still go to the destination configured in General tab.
  • Activation
    Click the notice “Settings changed! Please Click on Activate Changes to make modifications effect!” on the top of the web page to activate those configurations. Then you’ll be able to make outbound and inbound calls through DIDforSale VoIP trunks.