New API Method: Messaging/sendText()

The TextMarks XML-RPC API now has a new method to send an SMS to a single user.

The Messaging package now supports both the original 1) Messaging/postAlert() to broadcasts to all subscribers of a specific TextMark, as well as 2) the new Messaging/sendText() method to send to a single subscriber.

The PHP Client Library has been updated to provide easy access to this new call.

Example code:

require "TextMarksAPIClient.class.php";

// Authenticate to TextMarks API:
$sMyApiKey = 'MyAPIKEY_12345678';
$sMyTextMarksUser = 'mytmuser';
$sMyTextMarksPass = 'mytmp@$$word';
$sKeyword = 'MYKEYWORD';

// Send an SMS to a single TextMark subscriber:
$sTo = '415-555-1212';
$sMessage = "Order 534 ready for pickup! --EnviroClean 800-555-1212";
$tmapi = new TextMarksAPIClient_Messaging( $sMyApiKey, $sMyTextMarksUser, $sMyTextMarksPass );
$tmapi->sendText($sKeyword, $sTo, $sMessage);

Full documentation is available at the following resources:

Developer Center:

XML-RPC API Overview:

XML-RPC API Method Reference:

New sendText() Method:

Liked it? Share it!Tweet about this on TwitterShare on FacebookShare on Google+Share on LinkedInShare on StumbleUponShare on RedditPrint this pageEmail this to someone

You may also like...