About

Easyroute is a simple DID routing engine that uses a database lookup to determine how to route an incoming call. It uses a simple principle of numbers and gateways, with a many-to-one relationship. The lookup is performed by submitting the DID number to the database and getting a set of data fields in return. Easyroute can also perform number translation and set the account code for later processing. The database is supplied by the user. Easyroute can be called from the dialplan or from the API Event Socket interface.

Click here to expand Table of Contents

Setup notes

Enable mod_easyroute in trunk/modules.conf by uncommenting the line: #applications/mod_easyroute before building

Enable ODBC in the core when running configure: ./configure --enable-core-odbc-support

Enable the module in the config, edit modules.conf.xml, add the line: <load module="mod_easyroute"/>

API/Event Socket

The syntax for the easyroute API is:

easyroute <phonenumber> [field]

The field can be one of the five fields returned from the database. If the field is not specified then the following channel variables are set:

easy_destnum

easy_dialstring

easy_group

easy_limit

easy_acctcode

From there your application can use the variables for routing, processing, etc.