send_transactional_email
Send a transactional email via MailerCloud Email API. Supports HTML, AMP HTML, attachments, CC/BCC. Use version 1.0 for HTML only, 2.0 for AMP content. Two steps: call first WITHOUT confirm (or confirm: false) to get a preview (recipient count, from, subject) — nothing is sent. Show the preview to the user and get an explicit yes, then call again with confirm: true to send. dry_run: true returns the preview without sending even when confirm is true.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cc | No | CC recipients | |
| to | Yes | To recipients (array of name and email) | |
| bcc | No | BCC recipients | |
| from | Yes | Sender email address | |
| html | No | HTML content | |
| text | No | Plain text content | |
| confirm | No | Must be true to actually send. Leave false first to get a preview of recipients, sender and subject | |
| dry_run | No | Validate and show the send preview without sending, even when confirm is true | |
| subject | Yes | Email subject | |
| version | No | API version - 1.0 for HTML or 2.0 for AMP | |
| amp_html | No | AMP HTML content | |
| reply_to | No | Reply-to addresses | |
| from_name | No | Sender display name | |
| attachments | No | Attachments (array of name and url) |