Skip to content

Get message statistics

MessageStatistics collection allows retrieving performance statistics for a specified message. A specific period of time can be chosen. Statistics include counters of sent, delivered, bounced messages as well as number of generated clicks, opens, unsubscribes etc.

Request data format

Request URL parameters:

Element/attributeTypeNotes
apiKeystringYour API key, required for authentication. Required.
IDintMessage ID. Required as a part of address (not GET parameter). See example below.
startDatedateStart date. Optional. If not specified, message creation date will be taken. YYYY-MM-DD format.
endDatedateEnd date. Optional. If not specified, current date will be taken. YYYY-MM-DD format.
groupingstringResults grouping. Optional. If not specified, results will be grouped by whole business unit and message.
Available groupings are:
– DomainFamily

Examples:

https://api.esv2.com/v2/Api/MessageStatistics/123?apiKey=YOUR_API_KEY_HERE 

https://api.esv2.com/v2/Api/MessageStatistics/123?apiKey=YOUR_API_KEY_HERE&startDate=2010-05-20&endDate=2010-05-22

Response

Response Data element:

Element/attributeTypeNotes
SentintNumber of sent emails.
BouncedintNumber of bounced emails.
DeliveredintNumber of delivered (sent – bounced) emails.
OpensintNumber of opened emails.
UniqueOpensintNumber of opened emails by unique subscribers.
ClicksintNumber of link clicks.
UniqueClicksintNumber of link clicks by unique subscribers.
ClickersintNumber of unique subscribers that clicked any link.
ComplaintsintNumber of spam complaints.
UnsubscribesintNumber of “unsubscribe” link clicks.
BccintNumber of BCC emails sent. Available only for units with BCC feature enabled.

Response Data element  with a grouping parameter:

Element/attributeTypeNotes
MessageStatisticsarray[complex]Array of MessageStatistic elements.

MessageStatistic element children:

Element/attributeTypeNotes
IsSummaryRowbooleanIf set to true, marks the summary row of statistic table (values are sums of all other rows).
DomainFamilystringDomain family name. Returned only if grouping by domain families was requested.
SentintNumber of sent emails.
BouncedintNumber of bounced emails.
DeliveredintNumber of delivered (sent – bounced) emails.
OpensintNumber of opened emails.
UniqueOpensintNumber of opened emails by unique subscribers.
ClicksintNumber of link clicks.
UniqueClicksint
Number of link clicks by unique subscribers.
ClickersintNumber of unique subscribers that clicked any link.
ComplaintsintNumber of spam complaints.
UnsubscribesintNumber of “unsubscribe” link clicks.
Bccint
Number of BCC emails sent. Available only for units with BCC feature enabled.

Examples

Request:

GET https://api.esv2.com/v2/Api/MessageStatistics/764?apiKey=test_api_key1 HTTP/1.1 
Accept-Encoding: gzip,deflate 
User-Agent: Jakarta Commons-HttpClient/3.1 
Host: api.esv2.com

OK response:

HTTP/1.1 200 OK 
Cache-Control: private 
Content-Type: text/xml; charset=utf-8 
Content-Encoding: gzip 
Vary: Accept-Encoding 
Server: Microsoft-IIS/7.5 
Set-Cookie: ASP.NET_SessionId=conq5cmaq3mmpy455bkihvyd; path=/; HttpOnly 
X-AspNetMvc-Version: 1.0 
X-AspNet-Version: 2.0.50727 
X-Powered-By: ASP.NET 
Date: Mon, 24 May 2010 13:03:04 GMT 
Content-Length: 351 

<ApiResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
   <Data>
     <Sent>9</Sent>
     <Bounced>0</Bounced>
     <Delivered>9</Delivered>
     <Opens>19</Opens>
     <UniqueOpens>1</UniqueOpens>
     <Clicks>12</Clicks>
     <UniqueClicks>3</UniqueClicks>
     <Clickers>3</Clickers>
     <Complaints>0</Complaints>
     <Unsubscribes>0</Unsubscribes>
   </Data>
</ApiResponse>

Request with a grouping parameter:

GET
https://api.esv2.com/v2/Api/MessageStatistics/123?apiKey=YOUR_API_KEY_HERE&startDate=2010-05-20&endDate=2010-05-22&grouping=DomainFamily
Accept-Encoding: gzip,deflate
User-Agent: Jakarta Commons-HttpClient/3.1
Host: api.esv2.com

OK response: 

HTTP/1.1 200 OK 
Cache-Control: private 
Content-Type: text/xml; charset=utf-8 
Content-Encoding: gzip 
Vary: Accept-Encoding 
Server: Microsoft-IIS/7.5 
Set-Cookie: ASP.NET_SessionId=conq5cmaq3mmpy455bkihvyd; path=/; HttpOnly 
X-AspNetMvc-Version: 1.0 
X-AspNet-Version: 2.0.50727 
X-Powered-By: ASP.NET 
Date: Mon, 24 May 2010 13:03:04 GMT 
Content-Length: 351 

 <ApiResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
   <Data>
     <MessageStatistics>
       <MessageStatistic>
         <IsSummaryRow>true</IsSummaryRow>
         <Sent>9</Sent>
         <Bounced>0</Bounced>
         <Delivered>9</Delivered>
         <Opens>19</Opens>
         <UniqueOpens>1</UniqueOpens>
         <Clicks>12</Clicks>
         <UniqueClicks>3</UniqueClicks>
         <Clickers>3</Clickers>
         <Complaints>0</Complaints>
         <Unsubscribes>0</Unsubscribes>
       </MessageStatistic>
       <MessageStatistic>
         <DomainFamily>Other</DomainFamily>
         <Sent>5</Sent>
         <Bounced>0</Bounced>
         <Delivered>5</Delivered>
         <Opens>10</Opens>
         <UniqueOpens>1</UniqueOpens>
         <Clicks>7</Clicks>
         <UniqueClicks>2</UniqueClicks>
         <Clickers>2</Clickers>
         <Complaints>0</Complaints>
         <Unsubscribes>0</Unsubscribes>
       </MessageStatistic>
       <MessageStatistic>
         <DomainFamily>WP/o2</DomainFamily>
         <Sent>4</Sent>
         <Bounced>0</Bounced>
         <Delivered>4</Delivered>
         <Opens>9</Opens>
         <UniqueOpens>0</UniqueOpens>
         <Clicks>5</Clicks>
         <UniqueClicks>1</UniqueClicks>
         <Clickers>1</Clickers>
         <Complaints>0</Complaints>
         <Unsubscribes>0</Unsubscribes>
       </MessageStatistic>
     </MessageStatistics>
   </Data>
 </ApiResponse>
On this page
To top