Custom SMS Gateway Dev Kit

This page explains the necessary steps to integrate any 3rd party SMS API gateway into Layer's PVS Module using the Custom Dev Kit.

Requirements

  • API access credentials for the 3rd party SMS/API gateway

  • Knowledge of PHP

Please Remember

  • $phone variable will be automatically supplied, and contains the customer's phone number

  • $code variable will be automatically supplied, and contains a 4 digit code

The Steps

  • open customdevkit.php file (which can be found in the Layer's PVS Module folder)

  • provide the API credentials in the script, this depends on the Gateway provider. Some call them username/passwords, while others give them different names

  • provide the content of the SMS message in the $body variable, remember to include the $code variable in your message, as that is the code to be sent to the customer

  • build & execute the api request (have a look at example files from your gateway provider)

  • log the API Request attempt to help troubleshoot

Example

The example shows how to integrate Clickatell's API using the Custom Dev Kit.

Last updated