Class Message

java.lang.Object
com.mailosaur.models.BaseModel
com.mailosaur.models.Message

public class Message extends BaseModel
The email or SMS message processed by Mailosaur.
  • Constructor Details

  • Method Details

    • id

      public String id()
      Gets the unique identifier for the message.
      Returns:
      The unique identifier for the message.
    • type

      public String type()
      Gets the type of message.
      Returns:
      The type of message.
    • from

      public List<MessageAddress> from()
      Gets the sender of the message.
      Returns:
      The sender of the message.
    • to

      public List<MessageAddress> to()
      Gets the recipients of the message.
      Returns:
      The recipients of the message.
    • cc

      public List<MessageAddress> cc()
      Gets the carbon-copied recipients for email messages.
      Returns:
      Carbon-copied recipients for email messages.
    • bcc

      public List<MessageAddress> bcc()
      Gets the blind carbon-copied recipients for email messages.
      Returns:
      Blind carbon-copied recipients for email messages.
    • received

      public com.google.api.client.util.DateTime received()
      Gets the date/time that this message was received by Mailosaur.
      Returns:
      The date/time that this message was received by Mailosaur.
    • subject

      public String subject()
      Gets the subject of the message.
      Returns:
      The subject of the message.
    • html

      public MessageContent html()
      Gets the message content that was sent in HTML format.
      Returns:
      Message content that was sent in HTML format.
    • text

      public MessageContent text()
      Gets the message content that was sent in plain text format.
      Returns:
      Message content that was sent in plain text format.
    • attachments

      public List<Attachment> attachments()
      Gets an array of attachment metadata for any attached files.
      Returns:
      An array of attachment metadata for any attached files.
    • metadata

      public Metadata metadata()
      Gets further metadata related to the message, including email headers.
      Returns:
      Further metadata related to the message, including email headers.
    • server

      public String server()
      Gets the identifier for the server in which the message is located.
      Returns:
      Identifier for the server in which the message is located.