AttachmentController

Upload an attachment for sending using base64 file encoding. Returns an array whose first element is the ID of the uploaded attachment.

post/attachments

Request

  • Base URL: https://api.mailslurp.com
  • URL: https://api.mailslurp.com/attachments
  • Auth: API key in header x-api-key

Request body

contentIdstring nullable

Optional contentId for file.

contentTypestring nullable

Optional contentType for file. For instance application/pdf

filenamestring nullable

Optional filename to save upload with. Will be the name that is shown in email clients

base64Contentsstring required

Base64 encoded string of file contents. Typically this means reading the bytes or string content of a file and then converting that to a base64 encoded string. For examples of how to do this see https://www.mailslurp.com/guides/base64-file-uploads/

Response

Created

Changes

No recorded changes to this operation across all 1 revision of this API.