OpenACD Setup for sipXecs 4.2

This set of instructions are meant to serve as the manual instructions for integrating OpenACD and sipXecs on your own. OpenACD is integrated into sipXecs 4.4 and instructions can be found in OpenACD Setup. For an overview see OpenACD.

Environment Notes

For simplicity I've not configured domain name resolution of sip addresses (i.e. DNS does not have SRV records) so in my example i use either hostname or FQDN, never the domain name.

Install sipXecs

The version of FreeSWITCH 1.0.5 rpms that are available for download with sipXecs 4.2 do not have correct code. Unofficial tests have shown you can download and install the FreeSWITCH 1.0.7 rpms from the sipXecs 4.4 download directory into a 4.2 system and it seems to work.

Enable module in FreeSWITCH

Edit file
/etc/sipxpbx/freeswitch/modules.conf.xml.vm and enable the erlang module by adding this XML element

 <load module="mod_erlang_event"/> 

then hitting apply button on media services settings page.

Install and start OpenACD

There no rpm at the moment, but you can download and build OpenACD fairly easily.

rpm -ivh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-4.noarch.rpm
yum install git rubygem-rake
git clone git://github.com/Vagabond/OpenACD.git
cd OpenACD

# this step will download other git submodules and may take a while
rake

# to start openacd
./boot.rb

Create FreeSWITCH to OpenACD queue mapping

You need to edit the FreeSWITCH dial plans to answer incoming calls to sales queue and to trigger communication to openacd server there's a call for processing.

Edit FreeSWITCH dial plan template

Open the sipXecs-FreeSWITCH velocity template file /etc/sipxpbx/freeswitch/default_context.xml.vm with the following block:

...
<extension name="sales">
   <condition field="destination_number" expression="^300$">
     <action application="answer"/>
    <action  application="set" data="domain_name=$${domain}"/>
    <action  application="set" data="brand=1"/>
    <action  application="set" data="queue=Sales"/>
    <action  application="set" data="allow_voicemail=true"/>
    <action  application="erlang_sendmsg" data="freeswitch_media_manager  testme@starling inivr ${uuid}"/>
    <action  application="playback"  data="/usr/share/www/doc/stdprompts/welcome.wav"/>
    <action  application="erlang" data="freeswitch_media_manager:!  testme@starling"/>
  </condition>
</extension>
...

**NOTE: you'll want to replace "starling" with the host name of your local server.

Activate FreeSWITCH config

Now trigger a sipXconfig to rebuild FreeSWITCH configs by opening the "Media Server" configuration in "System/Servers/your-server-name/Media Server " and hitting the apply button. You will then see a link to restart the Media Server and go ahead and restart it. You can verify this step worked by looking for your chanages in the file /etc/sipxpbx/freeswitch/conf/dialplan/sipX_context.xml

Add sipXecs dial plan

You want to route calls for your ACD to FreeSWITCH.  Here we define freeswitch as a "gateway" and create a dial plan to direct the calls.

Gateway configuration

You'll want to configure these settings as show in "Figure: Gateway configuration" below

  1. Show advanced settings so we can configure non-standard port
  2. Enable gateway
  3. FQDN of your system.
  4. SIP Port that FreeSWITCH is listening on.
Figure: Gateway configuration

Dial plan Configuration

You'll want to configure these settings as show in "Figure: Gateway Configuration" below

  1. Enable the dial plan
  2. Pick incoming number that doesn't conflict with anything and you want for your ACD calls
  3. Select your destination number, little reason not to just pass the number right through unaltered.
  4. Select the gateway you configured in the previous step.
Figure: Dial plan Configuration

Activating dial plan

You'll want to allow the system to restart the necessary pieces of the system for the dial plan to become active.

What's next

You can now starting configuring queues. See OpenACD page for more insstructions.