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

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

Reporting Limits:

1 connection per 15 minutes

No connections from 12:00AM to 2:00AM Central Time

Overview 

Returns messages sent from various levels of the platform based on the category of messages. 

Syntax

C#

[OperationContractAttribute()] 
SBT.API.DataContracts.Common.WSReportSentMessagesResponse MessagesSentByType( 
   string securityToken,
   string orgCode,
   string fromDate,
   string toDate,
   string content_type,
   string note
)

 

WSDL

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

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

 

Parameters

securityToken

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

orgCode

- String[50] (Required) - Default Organization Code for the company, organization, division or group.

fromDate

- String[20] (Required) - Start date for report of messages received. Date format is [mm/dd/yyyy hh:mm:ss].

toDate

- String[20] (Required) - End date for report of messages received. Date format is [mm/dd/yyyy hh:mm:ss].

content_type

- String[10] (Required) - Type of the messages to be retrieved. Input numbers from 0 to 12 (0 - Help, 1 - Stop, 2 - Stop All, 3 - Stop and Stop All, 4 - VBT, 5 - Compliance Message, 6 - Keyword Message, 7- Template Message, 8 - No Dialogue Language Message, 9 - Notification Message, 10 - Unknown Subscriber Message, 11 - Outbound Message, 12 - Two-Way)

note

- String[200] (Optional) - This is an optional parameter passed to narrow the search to only return messages sent with the particular note.

Note: Date range should only include current and Previous month. 

Return Value

WSReportSentMessagesResponse
NameTypeDescription
Result bool True/False whether the call was successful or not.
ErrorCode int For Success/Failure it returns an error number.
Message string Message related to error code.
Response List <WSReportSentMessageRow>

If there are transaction details then they will be displayed
Group - Org name to which message was sent.
Code - Communication code from which message was sent to.
Phone - Phone number message was sent to.
ModeOfCommunication - Unique ID of Subscriber. (Note: recommend not to use this field. Instead use UniqueID field)
Message - content of message that was sent.
MessageCategory - Category of sent message. e.g. Outbound, Template, VBT, Two Way, Compliance, keyword etc.
MessageSubCategory - Sub Category of sent message. e.g. UI, API, HELP, STOP, STOPALL, VBT, Keyword etc.
TimeStamp - DateTime that the message was sent.
Note - Custom note added while sending the message
DeliveryStatus - Delivery Status of the message, for more info see the status code page.
DeliveryStatusID - Delivery Status ID of message, for more info see the status code page.
UniqueID - UniqueID of the Subscriber. UserName - User, who sent the message.
TransactionTicket - Transaction Ticket of the message.
TemplateID - Template ID of the template message (Displayed only for the Template Messages),
OrgCode - Default organization code, from where message sent.
Remarks - Remarks of the message, which is added while sending the message.

 

Examples

C#

lblError.Text = "";
ReportClient reportService = new ReportClient("ReportWSServiceHttpEndpoint");
    string securityToken = txtToken.Text; ;
    string orgCode = txtOrgCode.Text;
    string fromDate = dtFromDate.Text;
    string toDate = dtToDate.Text;
    string content_type = txtContentType.Text;
    string note = txtNote.Text;

    WSReportSentMessagesResponse wSReportSentMessagesResponse = reportService.MessagesSentbyType(securityToken, orgCode, fromDate, toDate, content_type, note);
        if (!wSReportSentMessagesResponse.Result)
            {
                //handle error
                lblError.Text = wSReportSentMessagesResponse.Message;
            }
        else
            {
                //handle success
                lblError.Text = wSReportSentMessagesResponse.Message;
            }

SOAP

Soap Request 
 
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://SBTService/ServiceContracts/">
   <soapenv:Header/>
   <soapenv:Body>
      <ser:MessagesSentbyType>
         <!--Required:-->
         <ser:securityToken>Security Token</ser:securityToken>
         <!--Required:-->
         <ser:orgCode>Org Code</ser:orgCode>
         <!--Required:-->
         <ser:fromDate>From Date</ser:fromDate>
         <!--Required:-->
         <ser:toDate>To Date</ser:toDate>
         <!--Required:-->
         <ser:content_type>content type (e.g. 0-12; 0-Help, 1-Stop...)</ser:content_type>
         <!--Optional:-->
         <ser:note>Search with Note. If it is blank all messages returned in the date range</ser:note>
      </ser:MessagesSentbyType>
   </soapenv:Body>
</soapenv:Envelope>
            

Soap Response
             
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
     <s:Body>
        <MessagesSentbyTypeResponse xmlns="http://SBTService/ServiceContracts/">
           <MessagesSentbyTypeResult 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:Result>true</a:Result>
              <a:ErrorCode>1441</a:ErrorCode>
              <a:Message>Successfully retrieved messages sent report</a:Message>
             <a:Response z:Id="i2">
		  <a:WSReportSentMessageRow z:Id="i2">
                   <a:Group>Org1->Div2->Grp01</a:Group>
		  <a:Code>10958</a:Code>
                   <a:ModeOfCommunication>SMS</a:ModeOfCommunication>
                   <a:Message>Message</a:Message>
		  <a:MessageCategory>Keyword</a:MessageCategory>
		  <a:MessageSubCategory>UI</a:MessageSubCategory>
		  <a:Phone>Phone</a:Phone>
                   <a:TimeStamp>8/30/2013 2:49:37 PM</a:TimeStamp>
                   <a:Note>NoteID</a:Note>
		  <a:DeliveryStatus>Delivered</a:DeliveryStatus>
		  <a:DeliveryStatusID>100</a:DeliveryStatusID>
		  <a:UniqueID>UniqueID of Subscriber</a:UniqueID>
                  <a:UserName>User name</a:UserName>
                  <a:TransactionTicket> Transaction Ticked ID</a:TransactionTicket>
                 <a:TemplateID>Template ID</a:TemplateID>
                 <a:OrgCode>Org Code</a:OrgCode>
                 <a:Remarks>Test Remark</a:Remarks>
              </a:WSReportSentMessageRow>
	     </a:Response> 
           </MessagesSentbyTypeResult>
        </MessagesSentbyTypeResponse>
     </s:Body>
  </s:Envelope>

JAVA

 ReportWSService srv = new ReportWSService();
 IReport iReport = srv.getReportWSServiceHttpEndpoint1();
 WSReportSentMessagesResponse res = null;

 String securityToken = "securityToken";
 String orgCode = "OrgCode";
 String fromDate = "08/22/2013";
 String toDate = "09/22/2013";
 String content_type = "1";
 String note = "test";

 try {
    	 res = iReport.messagesSentByType(securityToken, orgCode, fromDate, toDate, note);

 } 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/ReportWSService.svc?wsdl");
    $param = array(
	'securityToken' => 'securityToken',
	'orgCode' => 'orgCode',
	'fromDate' => '08/22/2013',
	'toDate' => '10/22/2013',
	'content_type'=>'1',
	'note' => 'note'
);

$response = $client->__soapCall('MessagesSentByType', array($param));
echo '<pre/>';
print_r($response);
if($response->MessagesSentByTypeResult->Result){
	echo 'Message: '.$response->MessagesSentByTypeResult->Message;
}
else {
	echo 'Message: '.$response->MessagesSentByTypeResult->Message;
}

?>

REST

Method: GET

URL: https://ui.solutionsbytext.com/SBT.App.SetUp/RSServices/ReportRSService.svc/MessagesSentbyType?securityToken=safdsfs&orgCode=dfsf&fromDate=01/31/2015 00:00:00&toDate=01/30/2016 00:00:00&content_type=conType&note=sampleNote

Response:

The response will be in JSON format like below:

{" MessagesSentbyTypeResult": {
   "Result": true,
   "ErrorCode": 1441,
   "Message": " Successfully retrieved messages sent report",
   "Response": { "List<WSReportSentMessageRow> response –
                         Sent Message By Type details like Code,Group,Message etc. Information will display" }
   }}


 

Send Feedback