Attach a file inline
Send the file encoded in base64 with itsfilename. The filename must include an extension, and the content must match it: a file named receipt.pdf must actually be a PDF.
attachments[] field. Use the same filename rules.
Reuse a file with the Files API
Upload a file once, then reference it by itsfile_id in as many emails as you like.
id starting with file_. Use it in attachments:
GET /api/v1/files lists your files and GET /api/v1/files/{id} returns one of them.
Embed an image inline
To show an image inside the HTML, give it acontent_id and point the src at cid: followed by that id. In multipart, send the file in inline[<content_id>].
content_id must be unique within the email.
Limits
File types that mail providers block are refused with
attachment_type_not_allowed. This covers executables and scripts, such as .exe, .bat, .js, .vbs, .ps1, .msi and .mdb. For these, zip the file or share a link instead.
For formats with a known signature (PDF, PNG, JPEG, GIF, WebP, ZIP, DOCX, XLSX, PPTX, ODT, ODS), the content must match the extension. Otherwise the request fails with attachment_content_mismatch.
Storage and retention
By default, PulseSend keeps a copy of each attachment so you can download it from the dashboard or the API. Setstore to false to delete the bytes as soon as the email is handed to the provider. The email keeps the file name, type and size.
Stored attachments follow the same retention as the email content: they are deleted after 30 days, and the name, type and size remain.
Download an attachment
download_url, valid for 5 minutes. Request the list again when you need a fresh link.

