The MIME parser does not support the full MIME standard but does support common uses of MIME, including SOAP with Attachments (SwA). The messages can be sent to the broker over HTTP or over other transport types, such as WebSphere MQ. Use the MIME domain if your messages use the MIME standard for multipart messages.
The multipurpose internet mail extensions (MIME) domain does not support Content-Type values with a media type of message.
Use the MIME domain and parser to parse and write MIME messages. The MIME parser creates a logical tree, and sets up the broker ContentType property. You can use Compute nodes, Java Compute nodes, and Mapping nodes to manipulate the logical tree. Set the Content-Type value using the ContentType property in the MIME domain.
The example below shows a simple multipart MIME message. The message shown is a SOAP with Attachments message with two parts: the root part and one attachment part. The boundary string MIME_boundary delimits the parts.
MIME-Version: 1.0 Content-Type: Multipart/Related; boundary=MIME_boundary; type=text/xml Content-Description: Optional description of message. Optional preamble text --MIME_boundary Content-Type: text/xml; charset=UTF-8 Content-Transfer-Encoding: 8bit Content-ID: <rootpart@example.com> <?xml version='1.0' ?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP-ENV:Header xmlns:ins="http://myInsurers.com"> <ins:ClaimReference>abc-123</ins:ClaimReference> </SOAP-ENV:Header> <SOAP-ENV:Body xmlns:ins="http://myInsurers.com"> <ins:SendClaim> <ins:ClaimDetail>myClaimDetails</ins:ClaimDetail> <ins:ClaimPhoto> <href>cid:claimphoto@example.com</href> </ins:ClaimPhoto> </ins:SendClaim> </SOAP-ENV:Body> </SOAP-ENV:Envelope> --MIME_boundary Content-Type: application/octet-stream Content-Transfer-Encoding: binary Content-ID: <claimphoto@example.com> myBinaryData --MIME_boundary-- Optional epilogue text
The diagram below is an example of a MIME logical tree. A MIME logical tree does not need to contain all of the children shown here. The value of the Content-Type header of a MIME message is the same as the ContentType field in the Properties subtree. The Transport-headers are headers from the transport that is used, such as an MQMD.
You can further parse the BLOB data in the tree if you know about the format of that MIME part. You might be able to find information about the format from its Content-Type field in the logical tree. Alternatively, you might know the format that your MIME messages take and be able to parse them appropriately. For example, you might know that the first MIME Part is always an XML message, and that the second MIME Part is a binary security signature.
You must specify how to parse other message formats, such as tagged delimited or binary data, within your message flow, because the MIME parser does not do this. You must also specify how to handle encoded and signed message parts, because the MIME parser does not process these.