SMS GATEWAY XML SPECIFICATION v1.0 | LAST UPDATED : 06 DECEMBER 2011
print

SMS_OPTOUT

Description :
This functionality is used when someone chooses to opt-out by sending an sms from their cellphone containing one or more of the keywords configured in the company's keyword dictionary. If the company has a blocklist URL configured, then the mobile number of the respondent will be sent to that URL. The XML posted to the URL will be the following:

Use :
<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?><XML><SMS_OPTOUT><SMS_SEND extension='{0}' to='{1}' /></SMS_OPTOUT></XML>

{0} – Is the username used to send the original sms to the user
{1} – is the mobile number of the user that replied

Example :
<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?><XML><SMS_OPTOUT><SMS_SEND extension='7865753' to='+27846555622' /></SMS_OPTOUT></XML>

CREDIT_REQUEST

Description :
A company can check the number of credits they have available by posting the following XML:

Use :
<XML><CREDIT_REQUEST user="{0}" reply="EMAIL:{1}" password="{2}" actual=" true"></CREDIT_REQUEST></XML>
{0} = The line number of the account that is being queried
{1} = Any email address can be used here. Although the reply email address is not used in this instance, it is required
{2} = The password of the account that is being queried

The system will return the following xml:
<?xml version="1.0" encoding="utf-16"?><XML><USER_CREDITS AVAILABLE="{0}" TYPE="{1}" /></XML>
{0} = The amount of remaining credits
{1} = Indicates either prepaid or postpaid

Example :
<XML><CREDIT_REQUEST user="12345a" reply="EMAIL:testmail@mycompany.co.za" password="a670hb9" actual=" true"></CREDIT_REQUEST></XML>