Business at the Speed of Text

Take a few minutes to watch how Solutions by Text can provide you with a compliant solution to enhance the customer experience and increase your bottom line through the power of texting.

Watch Videos

Two-Way Texting Changes the Game

Put real-time text responses in your customers’ pockets and real-time access at your staff’s fingertips.

Find Out More

Two-Way Texting Changes the Game

Put real-time text responses in your customers’ pockets and real-time access at your staff’s fingertips.

Find Out More

Business at the Speed of Text

Take a few minutes to watch how Solutions by Text can provide you with a compliant solution to enhance the customer experience and increase your bottom line through the power of texting.

Watch Videos

We're here for you.

Solutions by Text offers 24 hour support - both online and offline.

Give us a Call

Two-Way Texting Changes the Game

Put real-time text responses in your customers’ pockets and real-time access at your staff’s fingertips.

Find Out More

See What's New

Solutions by Text continues to evolve and develop its suite of products and features. Take a look at what's new in our world.

Read more

We Work With the Best

From retail to financial solutions, we’re constantly working with our clients to push the boundaries and find new ways to leverage SMS for business.

See Our Success Stories

Overview

This method returns the status of a message transaction by using the transaction ticket that is generated when a message is sent through all the send message APIs. When you send a message via sendMessage, sendMessageTemplate, the response contains a field called transaction ticket - this is the unique identifier for the particular transaction of sending a message. With this transaction ticket, you can use getMessageStatus to identify the current status of the message.

 

Syntax

C#

[OperationContractAttribute()]
SBT.API.DataContracts.MessageCenter.WSTransactionResponse GetMessageStatus(
   string securityToken,
   string transactionTicketId,
   string orgCode,
   string sentTo
)

 

WSDL

 

Production: https://ui.solutionsbytext.com/Sbt.App.SetUp/WSServices/MessageWSService.svc?singlewsdl

Staging: https://test.solutionsbytext.com/Sbt.App.SetUp/WSServices/MessageWSService.svc?singlewsdl

 

Parameters

securityToken

- String[1000] (Required) - SecurityToken to authenticate the user.

transactionTicketId

- String[50] (Required)- String[50] (Required) -When a message has been sent, transactionTicketId is generated and available in the response.

orgCode

- String[20] (Required) - Organization Code used when sending message - Organization, division or group.

sentTo

- String[20] (Required) Mobile phone number that the message was sent to.

 

Return Value

WSTransactionResponse
NameTypeDescription
Result bool True/False whether the call was successful or not.
ErrorCode int For Success/Failure it generates error number.
Message string Message related to the error code
Response List <TransactionDetail> Transaction details will be displayed if available.
* SendTo - Mobile phone number message was sent to.
* StatusCode - Status code of the message delivery (see Status Codes page)
* StatusMessage - Message that correlates to status code.

 

Examples

C#

MessageClient messageResult = new MessageClient("MessageWSServiceHttpEndpoint");

    string securityToken = txtToken.Text;
    string transactionTicketId = txtTransactionTciket.Text;
    string orgCode = txtOrgCode.Text;
    string sentTo = txtMobileNo.Text;
    
	WSTransactionResponse wSTransactionResponse = messageResult.GetMessageStatus(securityToken, transactionTicketId, orgCode, sentTo);
        if (!wSTransactionResponse.Result)
            {
                //handle error
                lblError.Text = wSTransactionResponse.Message;
            }
        else
            {
                //handle success
                lblError.Text = wSTransactionResponse.Message;
            }

SOAP

Soap Request 
 
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://SBTService/ServiceContracts/">
   <soapenv:Header/>
   <soapenv:Body>
      <ser:GetMessageStatus>
          <!--Required:-->
         <ser:securityToken>Security Token</ser:securityToken>
         <!--Required:-->
         <ser:transactionTicketId>Transaction ticket ID</ser:transactionTicketId>
         <!--Required:-->
         <ser:orgCode>Org Code</ser:orgCode>
         <!--Required:-->
         <ser:sentTo>Phone Number</ser:sentTo>
      </ser:GetMessageStatus>
   </soapenv:Body>
</soapenv:Envelope>

            
 Soap Response
             
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
   <s:Body>
      <GetMessageStatusResponse xmlns="http://SBTService/ServiceContracts/">
         <GetMessageStatusResult z:Id="i1" xmlns:a="http://SBTAPIService/DataContract/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:z="http://schemas.microsoft.com/2003/10/Serialization/">
            <a:ErrorCode>1238</a:ErrorCode>
            <a:Message>Successfully retrieved Message Status</a:Message>
            <a:Response>
               <a:TransactionDetail z:Id="i2">
                  <a:SendTo>Phone Number</a:SendTo>
                  <a:StatusCode>100</a:StatusCode>
                  <a:StatusMessage>Message was successfully delivered</a:StatusMessage>
               </a:TransactionDetail>
            </a:Response>
            <a:Result>true</a:Result>
         </GetMessageStatusResult>
      </GetMessageStatusResponse>
   </s:Body>
</s:Envelope>

JAVA

MessageWSService srv = new MessageWSService();
IMessage iMessage = srv.getMessageWSServiceHttpEndpoint1();
WSTransactionResponse res = null;

String securityToken = "securityToken";
String orgCode = "orgCode";
String sentTo = "12345678901";
String transactionTicketId = "li"; 
try {
	res = iMessage.getMessageStatus(securityToken, transactionTicketId, orgCode, sentTo);

} catch (Throwable e) {
		e.printStackTrace();
}

if(res == null ){
	System.out.println("Erron::");
	return;

}
if (res.isResult() == null || !res.isResult())
{
	//handle error
	System.out.println("ErrorCode::"+res.getErrorCode());
	System.out.println("ErrorMessage::"+res.getMessage().getValue());
}
else
{
	//handle success
	System.out.println("ID::"+res.getId());
	System.out.println("Message::"+res.getMessage().getValue());
}

PHP

<?php
   
$client = new SoapClient("https://ui.solutionsbytext.com/Sbt.App.SetUp/wsservices/MessageWSService.svc?wsdl");
$param = array(
	'securityToken' => 'securityToken',
	'transactionTicketId' => 'transactionTicketId',
	'orgCode' => 'orgcode',
	'sentTo' => '12345678999',
);
$response = $client->__soapCall('GetMessageStatus', array($param));
echo '<pre/>';
print_r($response);
if($response->GetMessageStatusResult->Result){
	echo 'Message: '.$response->GetMessageStatusResult->Message;
}
else {
	echo 'Message: '.$response->GetMessageStatusResult->Message;
}

?>

REST

Method: GET

URL: https://ui.solutionsbytext.com/SBT.App.SetUp/RSServices/MessageRSService.svc/GetMessageStatus?securityToken=safdsfs&transactionTicketId=16718-91801-19101&orgCode=haty161&sentTo=1234567891

Response:

The response will be in JSON format like below:

{" GetMessageStatusResult": {
   "Result": true,
   "ErrorCode": 1238,
   "Message": " Successfully retrieved Message Status",
   “Response”: { “List<TransactionDetail> response –
                              SendTo,StatusCode,StatusMessage Information will display” }
}}


 

Send Feedback