e-mail Monitoring/Sending Schema

From XAP Automation
Jump to: navigation, search

xAP Schema for Incoming Mail Monitoring v1.4

This describes a collection of xAP Message schema that provides notification of new emails.

Mail.Incoming.New

Class=Mail.Incoming.New

These messages inform when an entirely brand new not-seen-before email has been detected in some mailbox. It is normally sent only the once when the new email is first detected, but not subsequently.

Message
{
To=
-- mandatory
From=
-- mandatory
Subject=
-- mandatory
Timestamp=
-- mandatory
Msg=
-- mandatory
Total=
-- mandatory
MsgID={email message ID text}
-- mandatory
Org=
-- optional
DlyTo=
-- optional
}

Status is sent once for each mailbox each time it is checked.

Status
{
New={number of NEW messages detected}
-- mandatory
Total={total number of available emails in this mailbox}
-- mandatory (Must be >= New)
MailServer={name of mail server being reported on e.g. mail.bobshome.com}
-- optional (if not present all known mailboxes are implied)
UserName={username of mailbox on server being reported on e.g. "Bob"}
-- optional (if not present all known users at the mailbox are implied)
}

Mail.Incoming

Class=Mail.Incoming

These on the other hand inform of any available email messages for download. This is subtly different to Mail.Incoming.New in that whilst you may want a very responsive notification of a new email as soon as it has arrived, you won't necessarily want to know it's 'new' again in another 60seconds for instance.

So where Mail.Incoming.New is used for as near instant notification as possible, this class is used much less frequently to notify you of the complete set of currently available 'new' emails.

For example, say that at 1:10pm a new email from Bob arrives. A Mail.Incoming.New message would be dispatched. This would only be dispatched the once and would not be seen again unless a completely different email from Bob turns up.

But perhaps once every 30minutes the current set of available messages is broadcast to anybody interested so you are kept informed of what's available in case you missed the original Mail.Incoming.New notification.

Message
{
To=
-- mandatory
From=
-- mandatory
Subject=
-- mandatory
Timestamp=
-- mandatory
Msg=
-- mandatory
Total=
-- mandatory
MsgID={email message ID text}
-- mandatory
Org=
-- optional
DlyTo=
-- optional
}
Status.Request
{
MailServer=(name of mail server to be queried e.g. mail.bobshome.com)
-- optional (if not present all known mailboxes are checked)
UserName=(username of mailbox on server to be queried e.g. bob)
-- optional (if not present all known users at the mailbox are checked
}

Status.Request messages force an available mail report immediately.

Notes:

  • An empty message block will update ALL known mailboxes/usernames.
  • A missing or empty username will update ALL users at the specified mailbox (assuming one is configured and is recognised).
  • An empty mail server entry will cause all matching known mailboxes with the given user name to be checked.
Status
{
MailServer=(name of mail server being reported on e.g mail.bobshome.com)
-- optional (if not present all known mailboxes are implied)
UserName=(username of mailbox on server being reported e.g. bob)
-- optional (if not present all known users at the mailbox are implied)
Total=(total number of emails in this mailbox or on all mailboxes that match)
-- mandatory
}

Status messages can be sent out at some interval and report current mailbox status. For instance, for a particular email mail server these messages can report total numbers of available mails. By omitting the MailServer and UserName lines the information for all available mailboxes can be sent as a cumulative result in case that is of greater interest.

Notes:

  • Missing or empty MailServer and UserName values will accumulate the results for all known mailboxes/usernames.
  • A missing or empty username will accumulate the results for ALL users at the specified mailbox (assuming one is configured and is recognised).
  • An empty mail server entry will cause all matching known mailboxes with the given user name to be reported on.


Outgoing Mail Sending v1.1

This describes a xAP message schema that allows emails to be sent.

Unless otherwise stated a name/value pair is assumed to be mandatory.

Class=Mail.Outgoing

Message
{
To=(A semicolon-delimited list of e-mail addresses)
-- mandatory
From=(Email From: address field e.g. “User Name” )
-- mandatory
Subject=(Email Subject: field)
-- mandatory
Org=(Email Organization: field)
-- optional
CC=(semicolon-delimited list of e-mail addresses to receive carbon copy of email)
-- optional
BCC=(semicolon-delimited list of e-mail addresses to receive blind carbon copy)
-- optional
Priority=(High | Low | Normal)
-- optional
}

There will only ever be the one Message block in the Mail.Outgoing message. It is also a mandatory block. The following are optional.

Body.Text
{
Text.1=(paragraph to go in the email message)
-- mandatory
:
Text.X=(additional blocks of text)
-- optional (repeated sequentially as often as required)
}
Signature
{
Text.1=(A line of text to go in the signature)
-- mandatory
:
Text.X=(additional lins of signature text)
-- optional (repeated sequentially as often as required)
}