company logo

Help center

Go to Mailercloud
About usPricingContact us
All collectionsAPI PlatformMessage options for Email API & SMTP sends

Message options for Email API & SMTP sends

Every per-message option in one place — campaign type, open and inbox tracking, tags, campaign ID, content storage, auto-text, custom webhook data and your own List-Unsubscribe header — with the matching Email API field and SMTP header for each.

Every option below can be set per message. On the Email API they are JSON fields in the request; on the SMTP relay they are headers prefixed mld-track-, which Mailercloud consumes — recipients never see them.

The per-message options

Option

Email API field

SMTP header

Campaign type

metadata.campaignType

mld-track-campaign-type

Open tracking

automatic with a tracking domain

mld-track-opens

Tags

tags

mld-track-tag

Campaign ID

campaign_id

mld-track-campaign-id

Inbox tracking

inbox_tracking

mld-track-inbox

Content storage

store_content

mld-track-store-content

Auto text

auto_text

mld-track-auto-text

What each option does

  • Campaign type — TRANSACTIONAL or PROMOTIONAL; the default is PROMOTIONAL when omitted. This option controls unsubscribe behavior — see the classification article under Further reading.

  • Open tracking — automatic on the Email API whenever your sending domain has a tracking domain; on SMTP, true/false overrides the domain-level Open Tracking setting for one message.

  • Tags — labels for filtering the Activity list; up to 10 tags of 100 characters each. Comma-separated in the SMTP header.

  • Campaign ID — groups sends for reporting and inbox tracking; letters, numbers and hyphens, up to 100 characters.

  • Inbox tracking — set true to track inbox placement with the Inbox Tracker add-on; a campaign ID is then required.

  • Content storage — set false to skip storing the message content, recommended for sensitive bodies such as OTP emails.

  • Auto text — set false to send an HTML-only message as HTML only, without a generated plain-text part.

Custom data returned on webhooks

Attach your own reference data and get it back unchanged on every webhook event for the message: extra keys inside metadata.custom on the Email API, or one header per key prefixed X-MC-Custom- on SMTP (for example X-MC-Custom-order-id: 12345).

Limits: up to 10 keys; key names up to 50 characters using A–Z a–z 0–9 - _; values up to 256 characters, returned as strings. Keys that break the rules are dropped and listed in the webhook's custom_dropped array — see Webhooks in API Platform for the payloads.

📝 Note: The mld-track-* and X-MC-Custom-* headers are consumed by Mailercloud and stripped before delivery — the recipient never sees them.

Your own List-Unsubscribe header

You may supply your own List-Unsubscribe header; your value replaces the one Mailercloud adds to promotional messages. Rules:

  • Comma-separated values in angle brackets, each starting with https:// or mailto: — plain http:// is rejected.

  • List-Unsubscribe-Post, if supplied, must be exactly List-Unsubscribe=One-Click and requires List-Unsubscribe in the same message.

Headers Mailercloud manages

Headers the platform owns — From, Message-ID, Date, DKIM-Signature, Feedback-ID, authentication headers and the Content-* family, among others — are always set by Mailercloud. On the Email API, supplying a reserved header returns an error; on SMTP it is removed and replaced with the platform's own.

Further reading

  • Transactional vs promotional: how Mailercloud classifies your API and SMTP sends

  • How to use the suppression list in Mailercloud?

  • Webhooks in API Platform

  • SMTP relay guide

Need help?

If you have any questions about message options, contact us at [email protected] — the Mailercloud support team is ready to help.

Happy emailing! 🚀

Did this answer your question?
😞
😐
😁