...
Code Block |
---|
{ "pageNumber": 1, "status": "0", "description": "success", "numberOfRecords": 5, "pageSize": 100, "itemsReturned": 5, "numberOfPages": 1, "Messages": [ { "MessageId": "ef8ee563-9b05-4f65-8b2d-f49442fba447", "Received": "2022-11-17T14:02:04.557", "ResellerName": null, "CustomerName": null, "SendeName": "peterdemo2", "To": "61401001001", "From": "61401002003", "Message": "test campaign 17-10-22", "Charge": 1.00, "Outbound": true, "Status": "DELIVRD", "CampaignId": "836cd5d3-8554-46da-9dab-1cb9e71ed3dc", "CampaignName": "", "Validity": 0, "Encoding": "gsm", "NumberOfParts": 1, "DocumentId": null, "Keyword": null, "FileLocation": null }, { "MessageId": "abd849dd-79f4-4f8c-a35a-f4f731f83825", "Received": "2022-11-17T14:02:04.557", "ResellerName": null, "CustomerName": null, "SendeName": "peterdemo2", "To": "61401002007", "From": "61401002003", "Message": "test campaign 17-10-22", "Charge": 1.00, "Outbound": true, "Status": "DELIVRD", "CampaignId": "836cd5d3-8554-46da-9dab-1cb9e71ed3dc", "CampaignName": "", "Validity": 0, "Encoding": "gsm", "NumberOfParts": 1, "DocumentId": null, "Keyword": null, "FileLocation": null }, { "MessageId": "43ca58a4-0125-4609-8118-39995f472d56", "Received": "2022-11-17T14:02:04.557", "ResellerName": null, "CustomerName": null, "SendeName": "peterdemo2", "To": "61401000003", "From": "61401002003", "Message": "test campaign 17-10-22", "Charge": 1.00, "Outbound": true, "Status": "DELIVRD", "CampaignId": "836cd5d3-8554-46da-9dab-1cb9e71ed3dc", "CampaignName": "", "Validity": 0, "Encoding": "gsm", "NumberOfParts": 1, "DocumentId": null, "Keyword": null, "FileLocation": null }, { "MessageId": "a47baeb7-3ead-4091-8143-825372d7b0fc", "Received": "2022-11-17T14:02:04.557", "ResellerName": null, "CustomerName": null, "SendeName": "peterdemo2", "To": "61404857746", "From": "61401002003", "Message": "test campaign 17-10-22", "Charge": 1.00, "Outbound": true, "Status": "DELIVRD", "CampaignId": "836cd5d3-8554-46da-9dab-1cb9e71ed3dc", "CampaignName": "", "Validity": 0, "Encoding": "gsm", "NumberOfParts": 1, "DocumentId": null, "Keyword": null, "FileLocation": null }, { "MessageId": "8ee7e25b-0464-44bd-a9e2-671b337dc800", "Received": "2022-11-17T14:02:04.557", "ResellerName": null, "CustomerName": null, "SendeName": "peterdemo2", "To": "61401328025", "From": "61401002003", "Message": "test campaign 17-10-22", "Charge": 1.00, "Outbound": true, "Status": "DELIVRD", "CampaignId": "836cd5d3-8554-46da-9dab-1cb9e71ed3dc", "CampaignName": "", "Validity": 0, "Encoding": "gsm", "NumberOfParts": 1, "DocumentId": null, "Keyword": null, "FileLocation": null } ] } |
Message Volume Report
Overview
This method is user to get message history from either the WebApp history data table or the message history from MC5. The method return message data in the response. 100 record at a time can be fetched using paging. page size is set by the system to 100 records.
Address: api/MessageHistoryReportAPI/GetMessageVolumes
Method: POST
Data: x-www-form-urlencoded or JSON
Body Properties
parameter Name | Meaning | Notes |
---|---|---|
username | MC5 Reseller username | required |
password | MC5 Reseller password | required |
Source | Local, MC5 | Required - This is the data source from which the records are obtained |
CustomerName | Search for messages related to the customer only | Must be an exact match the WebApp Organisation Name |
DateFrom | Message Received or Sent Date Volume records include records for this date | Allowable date formats "dd/MM/yyyy HH:mm:ss", "d/M/yyyy", "d/M/yy", "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd", "dd/MM/yyyy HH:mm:ss zzz", "yyyy-MM-ddTHH:mm:ss", "yyyy-MM-ddTHH:mm:sszzz", "dd.MM.yyyy HH:mm:ss" |
DateTo | Message Received or Sent Date Volume records include records for this date | Allowable date formats "dd/MM/yyyy HH:mm:ss", "d/M/yyyy", "d/M/yy", "dd/MM/yyyy", "dd/MM/yy", "yyyy-MM-dd", "dd/MM/yyyy HH:mm:ss zzz", "yyyy-MM-ddTHH:mm:ss", "yyyy-MM-ddTHH:mm:sszzz", "dd.MM.yyyy HH:mm:ss" |
pageNumber | Page Number for data | note page size is 1000 message. iterate the method to retrieve all records within data set. |
country | use either the 2 character code or country name - safer to use the code so a match is found, eg Australia or AU | returns records for just one country - leave blank or set to null to retrieve volume for all countries |
Response
Code Block |
---|
{
"volumeReport": {
"incoming": [
{
"reseller": "resellerA",
"customer": "customerA",
"country": "Australia",
"integrationId": "",
"charged": 485.0,
"countTotal": 430,
"messageType": "SMS"
}
],
"outgoing": [
{
"reseller": "resellerA",
"customer": "customerA",
"country": "Australia",
"integrationId": "",
"charged": 139098.0,
"countTotal": 139116,
"countDelivered": 134115,
"countRejected": 21,
"countExpired": 3352,
"countUndeliverable": 1610,
"countNotRoutable": 18,
"messageType": "SMS"
}
]
},
"status": "0",
"description": "success"
} |