Basic Set-Up

As well as standard 3rd-party TAPI dialling using Windows or PABX TAPI drivers, IQX can initiate telephone calls with an HTTP call where this is supported by your phone system. The details of the URL format required will depend on your phone system and will need to be requested from the supplier.

A typical URL might look like:

http://192.168.7.231:546342/ivr/PbxAPI.aspx?func=make_call&from=<EXTENSIONNUMBER>&to=<NUMBERTOCALL>

where <EXTENSIONNUMBER> and <NUMBERTOCALL> have to be replaced by the relevant values. Your URL may look different.

To use this in IQX you need to open Maintenance | General Settings from the menu bar. Then search for the setting “Use Web Phone Dialling Mechanism” Enter the URL required in Value and replace the user extension number with the symbol ^ and the number to be dialled with the symbol # eg

http://192.168.7.231:546342/ivr/PbxAPI.aspx?func=make_call&from=^&to=#

Some phone systems install a local client program that supports a custom URL scheme such as Dial or Tel - these work just like very simple URLs eg:

tel://#

Then when you click on “Dial” on a phone number in IQX the appropriate http GET request will be made.

Note that the user extension number needs to be set up for each IQX user in Maintenance | Users.

More complex situations

POST requests required

Some phone systems require that POST requests with variables are made rather than a simple GET request with parameters in the URL. This can be done using an extended syntax eg:

{POST}http://192.168.7.231:546342/ivr/PbxAPI.aspx?func=make_call<&>from=^<&>to=#

{POST} tells IQX to make a POST rather than a GET request. <&> indicates that the following parameter should be sent as a POST variable instead of a URL parameter. Note that all post variables (ie <&> tokens) must come after any / all URL parameters. If there are no URL parameters, omit the initial ? eg:

{POST}http://192.168.7.231:546342/ivr/PbxAPI.aspx<&>from=^<&>to=#

{GET} can be used to make it clear when GET request is being used, but is optional eg:

{GET}http://192.168.7.231:546342/ivr/PbxAPI.aspx?func=make_call&from=^&to=#
Different URLs needed for different locations

If different URLs are needed for different branches of your business, you can do this by selecting the required Branch in Maintenance | General Settings from the Branch drop down. You will then see the “Use Web Phone Dialling Mechanism” - but now that setting applies ONLY to the selected branch.

URL needs additional information or is too complex for the basic mechanism

If you need additional substitutions or other more complex behaviour, you can use a database function to create the URL instead of entering it in General Settings.

To do this enter the word FUNCTION as the value for the “Use Web Phone Dialling Mechanism”. Then go to Maintenance | Database Functions | Communications | Generate Web Dial URL. The function which returns null by default can be edited here. Note that the output of the function should be a valid html URL, with spaces and other control characters appropriately escaped. The {PUT} behaviour described above works in the same way, but be aware that the ^ & # substitutions are not carried out. The telephone number is passed to the function as a parameter, other information can be looked up from the database - the UserStaffID variable (the StaffID of the logged in user) is especially helpful. As sample procedure which allows for a number of different telephone systems, specified by a localised (ie Branch) general setting:

ALTER FUNCTION "pears"."GenerateWEBDialURL"( in "Number" char(100) ) 
returns long varchar
begin
declare rv long varchar;
declare PhoneSystem char(50);
declare Extension char(100);
select WPKMaintainGetSwitchValue('SYNETY',Staff.AgencyID,'L'), Staff.Extension into PhoneSystem, Extension from Staff where Staff.StaffID = UserStaffID;
case PhoneSystem
       when 'MAIN' then set rv = string('http://sys1:82/api/call/makecall/',Extension,'/',[Number],'/9')
       when 'ALSR' then set rv =  string('http://phones2:81/api/call/makecall',Extension,'/',[Number])
       when 'ABSA' then set rv =  string('http://myphones:8180/api/call/makecall',Extension,'/',[Number])
       when 'AVYIA' then set rv =  string('http://main.intra.com:55340/phone.asmx/MakeCall?originatorExtension=',Extension,'&destinationPhoneNumber=',[Number],'&openLineCharacter=9')
    end case;
return rv;
end;

Please contact IQX support for help if required.

  • sa41-00.txt
  • Last modified: 2020/11/16 18:51
  • by Justin Willey