ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.

Send email assertion as MIME


Article ID: 225505


Updated On:


CA API Gateway


The goal is to send an attachment using the Send Email assertion with MIMEs. There's an error when setting MIMEs in a context variable. Any idea what this error means and what is required to send the contents of the file as an attachment with MIME?

ERROR: Invalid Email attachment; Unable to extract attachment name from the MimePart: Invalid or empty Content-Disposition header


The Content-Disposition header is missing.


API Gateway: 10.0 1.0.1


This header needs to be added for each section that you want an attachment for:

Make sure you check off the 'Mime Part(s) Variable checkbox is checked:

When the service is executed, an email is sent with two attachments:

Additional Information

A sample policy has been provided.


1633521846756__sendEmailwithMIME.xml get_app