






export DIGITALOCEAN_TOKEN=<Digital Ocean token key>
git clone https://github.com/dOpensource/dsiprouter
cd dsiprouter/resources/terraform/do
copy terraform.tfvars.sample terraform.tfvars
terraform initpvt_key_path="C:/Users/alems/Working/andrew" (adjust using path format, andrew is actually the pvt key)
dsiprouter_prefix="dev"
number_of_environments=1
pub_key_name="andrew"terraform applyterraform apply -var branch=v0.643
<list name="my_list_001" total-weight="2">
<node name="978fefdd-45cd-4457-8ecd-5d82eaea3b12" weight="1"/> <!-- my_gateway_001 - its just comment with actual GW name -->
<node name="1a8d448d-e06e-2dab-b6f9-4421a98e4d8e" weight="1"/> <!-- my_gateway_002 -->
</list>
fs_cli > reloadxml
fs_cli > distributor_ctl reload
sipp -sn uac -r 7 -rp 2000 <ip of server>sipp -sf sipproxyfriendly.xml -r 7 -rp 2000 <ip of server>We are introducing a new API that will enable the provisioning of extensions within a backend media server. The API will provide an abstraction layer for provisioning different backend media servers. The first release will focus on FusionPBX.
dSIPRouter has a concept of an Endpoint Group. An endpoint group can be mapped to a FusionPBX Cluster. When this happens the domains from FusionPBX is automatically sync’d with dSIPRouter. We will leverage the existing connection to enable the ability to provision and update Domains and Extensions within FusionPBX. In the future, we will support FreePBX and other media servers as well. Hence, giving users one API for provisioning users and dSIPRouter handles the complexity of translating the request into the backend media server.
The feature will be available in 0.642. You can provide comments and feedback on the API by submitting comments in the GitHub issue which can be found here
/mediaserver/domain/
/mediaserver/extension/
{
   domain_id:
   name: string,
   enabled: boolean,
   description: string,
   config_id: endpointgroup_id | conf_id
}
{
    type: single| multiple,
    num_of_extensions: integer,
    attributes: {
      domain_id: string | null,
      account_code: string,
      extension: string,
      password: string|null ,
      outbound_caller_number: string|null,
      outbound_caller_name: string:null,
      vm_enabled: boolean,
      vm_password: string,
      vm_notify_email: string,
      enabled: boolean,
      config_id: endpointgroup_id | conf_id
    }
}
The following example will provision a new Endpoint Group in dSIPRouter and a Domain and Extension in FusionPBX. Note, that the API will also support updating and deleting as well.
1) The user will create an endpoint group to represent a FusionPBX standalone instance or a FusionPBX cluster
https://{{DSIP_ADDR}}:5000/api/v1/endpointgroups
They will receive an endpoint group id, which will be used for provisioning the backend media server
2) The user can then create a new domain
https://{{DSIP_ADDR}}:5000/api/mediaserver/domain/
{
   domain_id: null
   name: AprilandMackCo,
   enabled: true,
   description: "April and Mack Co,
   config_id: 64
}
The user will receive the domain_id, let’s assume its 98
3) The user can create one user or a set of users. We are going to create 10 users
https://{{DSIP_ADDR}}:5000/api/mediaserver/extension/
{
    type: "multiple",
    num_of_extensions: 10,
    attributes: {
      domain_id: 98,
      account_code: "124-24245",
      extension: "1000",
      password: "starterpassword" ,
      outbound_caller_number: "8889072085",
      outbound_caller_name: "dOpenSource",
      vm_enabled: true,
      vm_password: "94145",
      vm_notify_email: "",
      enabled: true,
      config_id: 64
    }
}
This API will create 10 extensions starting from 1000 with the same attributes. You can also create a single extension.
dSIPRouter 0.63 was recently released with out of the box support for Twilio Elastic SIP Trunking. The design goal for the first release of this feature was to make it simple for a user to download dSIPRouter and setup Twilio as the carrier.
You have a Twilio account. It only takes a few minutes to create an account. You can create an account by going here
Enter Elastic SIP Trunks in the top right search bar and click enter. Notice that Twilio gives you a double digit Trial Balance. This is better then most SIP providers that I worked with in the past.

Click the + sign to create a new SIP Trunk. Enter a name for your SIP Trunk and click “Create”

You will see a screen that looks like this

Since we are focused on sending calls outbound we are going to click on the “Termination” menu option. We are going to use IP Authentication. So, we just need to define a unique SIP URI for signaling to Twilio. Twilio doesn’t accept SIP requests that come from an IP address. Also, we need to define an Access Control List that contains the IP address of your dSIPRouter instance. If you have multiple instances of dSIPRouter then define all of the IP addresses.

This is all we need to do on the Twilio side. In the next section we will focus on configuring dSIPRouter

Click on the Carrier Group that you just added
Enter the Twilio SIP URI that you defined in the Twilio portal

Click “Reload Kamailio”
Click on the Default Outbound Route and select Twilio Outbound

In this section we are going to use IP authentication to send a call using a softphone.

Click “Reload Kamailio”
The purpose of this tutorial is to explain how to configure the Yealink W60P Cordless DECT IP Phone with FreePBX, Asterisk of FusionPBX. We will assume that you have the extension already configured in one of the aforementioned systems. Therefore, we will focus on the steps needed to configure the phone.
I must note that the experience with configuring the Yealink W60P was much better then configuring the Panasonic KX-TGP600
The high-level steps needed to complete this are listed below. We will go into detail for each section.
Locate Web Management UI IP Address
Log into theWeb Management GUI
Configure the phone settings via the Web Management GUI
Required Fields
| Line Action | 
| Label | 
| Display Name | 
| Register Name | 
| Username Name | 
| Password | 
Optional Fields
These fields are only needed if you have a proxy server in front of your media server such as Kamailio or OpenSIP’s
| Enable Outbound Proxy Server | 
| Outbound Proxy Server 1 | 

We will go over how to setup the call center module. The call center module is used for creating an inbound queue for connecting inbound callers with agents registered to your system.
Select the Domain in which you would like to set up the call center in.
Select Apps→ Call Center→ plus sign(+) to add a call queue.
Fill in the necessary information and SAVE:
All the others fields are pretty much standard. If you would like detailed information for each field you may find it here.

Click the plus sign (+) to add agents in the Call Center Agents screen.
Fill in the necessary fields:
Agent Name: Select the corresponding account you have created
Type: two types supported, callback and uuid-standby. callback will try to reach the agent via the contact fields value. uuid-standby will try to directly bridge the call using the agent uuid.
Contact: Select the extension you want to associate with that agent
Status: You can select status from here but it will be interacting with it later so its not an important field for now
Agent Logout: This is where you can select a time of the day where automatically the agent will be logged out. As it says it requires a service to enforce it.

While in the Call Center Agent screen you may also add a Agent ID and Password if you would like the agents to be able to log in on their own.
Note: Agent ID can be a string of numbers that will be used to select via the telephone diakpad.
Agent Call Center Log in
Agents can login to call center with *22 from the phone (hardphone or softphone) or via the FusionPBX web interface. Admin and Super Admin accounts can also log other agents in or out.