/
1.7.3 Local DIDs inventory

1.7.3 Local DIDs inventory


In this scenario you as a provider have a PSTN gateway connected to PTSN over E1/T1 trunks or SS7 interface from a telecom operator. The operator can supply you with a pool of phone numbers which will be routed through the trunks to your gateway. It means that if someone calls any phone number from the pool the call will be sent to your gateway.

The gateway has to be configured to forward all SIP traffic to the voipswitch address. The SIP URI in the TO header of the INVITE method should look like phonenumber@voipswitchaddress     for example 44208445566@192.168.1.5

On voipswitch you will have to upload the numbers into the database. It will be the pool of numbers which can be ordered by customers. The numbers have to be grouped into countries and areas. Clients will be able to select a location of the number and, if allowed, to pick the number.

Local DIDs pricing

Price for DIDs can be assigned only to countries (not to areas). To put a price to particular country go to DIDs/Pricing menu. Then click on the Add button. The Import countries action will work only in a DIDs API scenario.


The supplier field shows Local supplier. It means that the DIDs are from your own DIDs which will be stored in the database, as opposite to using external APIs like with DIDs providers.

The next field, Country name, is just a descriptive name of the country. Country code is an ISO code of the country. Next is the country phone code.

The three last fields are related to billing:

  • Setup fee – one-time fee charged on DID’s purchase
  • Monthly fee- charged on the purchase and then on the end of each period
  • Channel fee – it is also monthly, the charge is per one channel, number of channels can be selected by the client during purchase

Saving the data will open an edit view of the added country.


From this level you can add areas using inside the areas tab by clicking add button on the left. The areas are only needed to let clients choose the desired number. An area does not have to be a geographical place, it can be for example toll free type of numbers.

Number assigned/Number used columns shows how many of DIDs from a given location is already in use, i.e. purchased by clients.

List of all countries is presented in the main table at DIDs/Pricing. The search component allows for looking for numbers per country code, country name and per a DID provider/supplier.


Note: you have to add all countries and areas which you want to offer to clients. Only those will be presented in appropriate DIDs ordering menus in softphones and in the Portal.

Importing DIDs to local inventory

Next step after setting pricing is to import the numbers with associated countries and areas to the database. Go to DIDs/local menu and click Import button.


The dialog will let you drag and drop a file in CSV format. The format of data has to be as follows:

COUNTRY ISO CODE, AREA CODE, PHONE NUMBER

For example:

countrycode,areacode,phonenumber

UK,208,442081368000

UK,208,442081368001

UK,208,442081368002

UK,208,442081368003

UK,208,442081368004

UK,208,442081368005

UK,208,442081368006

UK,208,442081368007

UK,208,442081368008

UK,208,442081368009


NOTE*   ISO 3166-1 alpha-2   -should be used which have 2 characters ,example  US instead of USA.


The country codes and area names must match the ones defined in pricing. Otherwise will not be imported.

The all imported numbers are shown in the list in the DIDs/Local menu.


From this level you can manage the inventory. The numbers can be filtered by country, area and status. You can see which numbers are available for sell and which already assigned to a client.

The status can be one of the following:

  • Available – the phone number is in the pool of numbers for sale, they can be ordered by clients
  • Assigned – already taken by a client, will remain in this state until the number is cancelled
  • Cancelled – either by the client (resignation) or by the system (no payment), numbers in this state are not in the pool of the numbers for sale

The reason for the cancelled state is that providers often keep the number for some time before offering to others, in case if the client would want to get the number back after settling the bill.

Change status function (a button in the top left corner) allows for bulk change of the numbers in the cancelled state to the available state.

You can change all cancelled numbers or only from a particular country or country and area.

Related content