FetchMessage
You may want to include the test message if you are preparing your own reports or if you chose to remove the test message from the formatted HTML. The “FetchMessage” function provides the means to obtain the message that the EmailReach servers received. This may provide useful information about changes that were made to the message by the various services that handled it.
The function accepts only two parameters: the authToken and the messageID assigned by the sending server. In C#, the declaration is:
MessageObject FetchMessage(string authToken, string messageID)
and the WSDL is:
<s:element name="FetchMessage">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="authToken" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="messageID" type="s:string" />
</s:sequence>
</s:complexType>
</s:element>
The returned structure contains the message in two fields: the “body” field and the “headers” field. The other fields provide additional information related to the message: the sender’s email address, the recipient’s address, the timestamp showing when it was received and the message subject.
In C#, the structure declaration is:
struct MessageObject
{
string messageID;
string subject;
string from;
string to;
long dateSent;
string body;
string headers;
}
and the WSDL is:
<s:complexType name="MessageObject">
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="messageID" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="subject" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="from" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="to" type="s:string" />
<s:element minOccurs="1" maxOccurs="1" name="dateSent" type="s:long" />
<s:element minOccurs="0" maxOccurs="1" name="body" type="s:string" />
<s:element minOccurs="0" maxOccurs="1" name="headers" type="s:string" />
</s:sequence>
</s:complexType>
|