Develop > Controller layer > Integrate with back-end systems and external applications > Outbound services > Send services


Add e-mail parts or attachments services

The standard e-mail transport, as well as some other transports, allow attachments to be added to messages.

The following methods of the SendMsgCmd command allow users of the messaging system to attach content parts, or attachments, to messages:

public void addContentPart(byte[] msgAttachment)

This method offers a simple way to add content parts to a message. For the e-mail transport, a "content part" refers to an attachment. The msgAttachment parameter represents the content to be added to the message. Note that this must be the actual content of the part, translated into byte format.

public void addContentPart(byte[] msgAttachment , String partName, String partType)

This method gives you greater flexibility in adding content parts to a message. The msgAttachment parameter represents the content to be added to the message. The partName parameter represents a name to be used for the content part. The partType parameter represents the MIME type of the part being sent. For example, the partType for Mime Email could be 'text/html', or 'text/plain', which is the default.


Related concepts

Outbound messaging system


Related tasks

Create an outbound message

Related reference

Error handling in the messaging system composition service

Example: Using the messaging system composition service


+

Search Tips   |   Advanced Search