CMS Web Services - v4.0.6459.17834 [cms-b]

<back to all web services

MessageListQuery

Returns a list of messages and message details based on the query parameters (Default: Messages seen in the last 24 hours)

The following routes are available for this service:
POST,GET/message/list/query
MessageListQuery Parameters:
NameParameterData TypeRequiredDescription
QueryTypebodyMessageQueryTypeNoType of query (one of: Action,Addressee,Cms,Gateway,MessageId,Sender,Source,Subject)
QueryArgumentbodystringNoParameter value for selected query type (required when query type specified)
HistoryHoursbodyintNoNumber of hours of history to include (default: 24)
RecordLimitbodyintNoLimit number of records returned (default: 1000)
WebServiceRequest Parameters:
NameParameterData TypeRequiredDescription
KeyformstringYesWeb service access key -- allows use of Winlink web services
MessageListQueryResponse Parameters:
NameParameterData TypeRequiredDescription
MessageListformList<MessageListQueryRecord>No
WebServiceResponse Parameters:
NameParameterData TypeRequiredDescription
ResponseStatusformResponseStatusNo
MessageListQueryRecord Parameters:
NameParameterData TypeRequiredDescription
TimestampformDateTimeNo
MessageIdformstringNo
SizeformintNo
AttachmentsformintNo
ActionformstringNo
SourceformstringNo
CmsformstringNo
GatewayformstringNo
SenderformstringNo
SubjectformstringNo

To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv

HTTP + JSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /message/list/query HTTP/1.1 
Host: cms.winlink.org 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	QueryType: None,
	QueryArgument: String,
	HistoryHours: 0,
	RecordLimit: 0,
	Key: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	MessageList: 
	[
		{
			Timestamp: 0001-01-01,
			MessageId: String,
			Size: 0,
			Attachments: 0,
			Action: String,
			Source: String,
			Cms: String,
			Gateway: String,
			Sender: String,
			Subject: String
		}
	],
	ResponseStatus: 
	{
		ErrorCode: String,
		Message: String,
		StackTrace: String,
		Errors: 
		[
			{
				ErrorCode: String,
				FieldName: String,
				Message: String,
				Meta: 
				{
					String: String
				}
			}
		],
		Meta: 
		{
			String: String
		}
	}
}