Adding the RESTful Application ("REST App") to a device requires that you have the RESTful Application module installed along with a valid license. To purchase the RESTful Application module, please see this wiki on how to Purchase Commercial Modules. You will also need to make sure you have a valid Commercial End Point Manager module and the Free Commercial RESTful API module installed.
If you are using a Sangoma S500 or S700 phone you will not need to purchase the Phone Apps module or End Point Manager Module as these modules will work with Sangoma Phones our of the box with no license purchasing needed.
Once all the above requirements are met, you can go through the below setup.
Verify RESTful API is Enabled for the User
- Review the User Management Module User Guide for instructions on enabling Rest API for a user. Make sure you have enabled the desired Rest Apps for the user.
Map Applications to Phones
- Log into your commercial End Point Manager (EPM) and either create or edit a template for a supported device. In our example, we are going to pick Aastra and edit our "sample" template. For the purpose of this wiki, we will assume you know how to use the commercial EPM, and we will only cover how to add an application to a template. For more information on how to use the commercial EPM, please see the End Point Manager wiki.
- Select a phone model in order to edit its button configuration. In our example we'll pick the 53i.
- To program a button for a Rest App:
- In the Type drop-down, select XML-API.
- In the Value drop-down, select one of the available Rest Apps.
- When finished, click the Save Model button.
- Click the Save Template or the and Rebuild Configs button.
- Finally, be sure to map devices to use this template in the Extension Mapping section.
Open the RESTful Phone Apps Port if Using External Phones
- If your phone is external from your PBX, and your PBX is behind a firewall, you will need to open the RESTful Apps port. To do this, go into the System Admin module and click on the Port Management section.
- Locate the RESTful Phone Apps port.
- Optional: You can change this port if you would like. If you change it, click the Update Now button to save the changes.
- Do not forget to open your firewall for this port if external phones will connect to the PBX and need access to the RESTful Phone Apps. The phones will use this port when connecting to the phone apps.
Start the Process Script
After you have licensed Phone Apps, you need to start the demon that watches for hints the first time, as this could not be started when there was no license. This script will be auto-started any time amportal start is run, which includes on boot up.
[root@mybox ~]# /etc/init.d/restapps restart
Shutting down REST applications daemon: [FAILED]
Starting REST applications daemon: [ OK ]