Context

Brevo’s send-transactional-email endpoint (POST /v3/smtp/email) takes attachments with only three fields: url, content (base64) and name. There is no Content-ID field. Brevo staff and third-party library docs (for example Anymail) state that inline CID images are not supported, and Brevo’s FAQ recommends hosted image URLs instead.

Insight

It works anyway, as long as the cid: value is exactly the attachment’s name:

{
"attachment": [{ "name": "acme-mail-logo.png", "content": "<base64>" }],
"htmlContent": "<img src=\"cid:acme-mail-logo.png\" alt=\"Acme\">"
}
  • Brevo rewrites the reference to its own generated ID (cid:<date>.<n>@mail.0), and the image renders inline.
  • A cid: that doesn’t match an attachment name (for example cid:logo with an attachment named logo.png) renders blank.
  • Brevo does a plain text replacement of the file name across the whole HTML, including alt text and visible text. Use file names that can’t appear anywhere else in the email (prefix them).

Caveats

  • Undocumented, so it may change without notice. Keep a hosted-URL fallback in your code.
  • Brevo re-hosts external <img> URLs on its own CDN anyway, so for the fallback any public URL is enough.
  • Verified in one email client (HEY). Check Gmail and Outlook before relying on it.
  • To check what was actually sent, read the stored body back with GET /v3/smtp/emails/{uuid}. It shows the rewritten cid: references.