iSMS Local Gateway setup
Note: iSMS is available only to Pro and Enterprise Magpi users.
Why Set Up a Local Gateway?
If you use Magpi "off the shelf" (that is, with no special configuration), respondents to your iSMS and other messaging will receive the system texts from our US or UK numbers. When they respond, it will also be to those numbers, and the cost of sending international text messages can be substantial.
You can reduce those costs by setting up a "local gateway" using an Android phone with a local SIM card. That phone, running the SMSSync utility program created by our friends at Ushahidi, will act as a gateway, or bridge, between the local SMS system and the internet-based Magpi system. On a practical level, it means that the respondents to your iSMS messaging will be sending their texts to a local number, at a lower cost.
It is best to select a well-reviewed and capable device, with plenty of RAM memory, to serve as your gateway. Cheap devices with little memory or slow processors are bound to cause trouble.
Setup at Magpi.com
The Settings Page
2. On the settings page, click on the SMS Tab, highlighted in the image above, and:
- Check the “Enable iSMS local gateway” checkbox
- Enter “Local gateway secret key” or click on “Generate a new secret key?” link to automatically generate one for you. (Note: The key has to be unique in the entire Magpi system.)
- Enter the local gateway phone number (iSMS server). This is the phone number for the SIM card in the Android phone with SMSSync installed.
3. Once that is done the set up is complete on the website, now go to the mobile phone with SMSSync installed.
Setup on the Android Phone
1. Download SMSSync App from google play on the link below or search google play for “SMSSync”
2. When you open the app, click on the menu button at the top left side of the app as shown below. It will give you the menu options below on the second screenshot.
3. Click on the menu option Integrations, this will open up the integrations screen show below.
- Enter any Title
- Enter the sync url in the format: https://MAGPI_USERNAME:SECRET_KEY@www.magpi.com/isms/smssync (MAGPI_USERNAME is the registered username in Magpi, SECRET_KEY is the local gateway secret key you entered on step 2. So if your username is support and the key you entered is data, then url will be https://support:email@example.com/isms/smssync
- Leave Secret Key blank
- Click Add to save and check the new Integration checkbox.
On the Integration screen check the “Start SMSSync service” checkbox and immediately the sync icon will show that it's running
4. Once that is set up, go back to the main screen and click on the menu button at the top left side and click Settings. The screen below will be opened.
Click on General and enter the field below.
- Unique ID – Enter the phone number entered in step 2iii. This should be the number of the phone with SMSSync installed. (Make sure the number on step 2iii is the same as the number entered here.)
- Enable SMS Delivery Report and Click OK to save.
5. Go back to Settings screen and click on Automation. This will open the screen below.
- Check Auto Delete Messages checkbox
- Check Enable Auto Sync checkbox
- Click on “Auto sync frequency” to set frequency time for syncing. Set it to 1 second.
- Check Enable Task Checking checkbox
- Click on “Frequency” to set task checking frequency time. Set it to 1 second.
- Enable "Message Result API"
- Click back button to save settings.
Once you have set up the setting on the Magpi web app and SMSSync android app. Send a text message 'Exit All' to the local gateway number. This will unsubscribe your phone number from any pending iSMS sessions.