AssignKeyword

From CDYNE Wiki
Jump to: navigation, search

Contents

AssignKeyword Request

Parameter Name Data Type Sample Input
LicenseKey: Required to authenticate users invoking this Web Service.

Trial Key. Production Key.

Guid F01d89fd-5155-5455-5585-e84ab8de8591
SMSKeywords: An array of Keyword requests shown below.
KeywordRequestInfo

Keyword: New keyword.

ShortCode: ShortCode to assign new keyword to.


String

String


Keyword27

10101

AssignKeyword Response

Parameter Name Data Type Sample Output
ReturnCode: Return code for method call. Should always return NoError for AssignKeyword(). String NoError
SMSKeyword: An array of keyword responses shown below.
KeywordResponseInfo

EntryDate: DateTime in UTC of when keyword was added.

Keyword: Keyword.

ReturnCode: Return code for this keyword. Can return:
ShortCodeInvalid, KeywordInvalid, KeywordAdded, ShortCodeNotAssignedToKey, KeywordAlreadyInUse, InternalError

ShortCode: ShortCode that this keyword is assigned to.


Datetime

String

String


String


2010-05-11T19:17:28

Keyword27

NoError


10101


Assign Keywords Code Examples

PHP

 
 
$client = new SoapClient('http://sms2.cdyne.com/sms.svc?wsdl');
$lk = 'f01d89fd-5155-5455-5585-e84ab8de8591';
$KeywordsArray1 =  'TestKeyword';
$ShortCode1 = '74121';
 
$RequestArray = array(
                                  array(
                                   ShortCode'=>$ShortCode1,
                                   'Keyword'=> $KeywordsArray1,
                              )
                );
$request = new AdvancedCallRequestData($lk,$RequestArray);
//print_r($request);
$result = $client->AssignKeyword($request);
print_r($result);
class AdvancedCallRequestData {
  public $AdvancedRequest;
  function AdvancedCallRequestData($licensekey,$requests) { 
            $this->KeywordRequest = array();
            $this->KeywordRequest['LicenseKey'] = $licensekey;
            $this->KeywordRequest['SMSKeywords'] = $requests;
  }
}
?>
Personal tools
Namespaces

Variants
Actions
Navigation
Tools

Trial Key