preview_email
Validate and preview an email message without sending it. Resolves sender, checks payload, reads local attachments, and returns summary with warnings.
Instructions
Dry-run an email WITHOUT sending it. Resolves the final from (incl. RESEND_FROM default), validates the payload, reads/sizes any local attachments, and returns a summary plus warnings. Use to verify a message before calling send_email.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | No | Sender, e.g. "Acme <hello@acme.com>". Falls back to RESEND_FROM. Domain must be verified. | |
| to | Yes | Recipient address(es), e.g. "user@example.com" or ["a@x.com","b@y.com"] | |
| subject | Yes | Email subject line | |
| html | No | HTML body (provide html and/or text) | |
| text | No | Plain-text body (provide html and/or text) | |
| cc | No | Recipient address(es), e.g. "user@example.com" or ["a@x.com","b@y.com"] | |
| bcc | No | Recipient address(es), e.g. "user@example.com" or ["a@x.com","b@y.com"] | |
| replyTo | No | Reply-To address(es). Falls back to RESEND_REPLY_TO. | |
| scheduledAt | No | Schedule for later: ISO-8601 or natural language like "in 1 hour" / "tomorrow at 9am" | |
| attachments | No | ||
| tags | No | ||
| headers | No | Custom headers, e.g. {"X-Entity-Ref-ID": "123"} | |
| templateId | No | Send using a saved template instead of html/text | |
| templateData | No | Variables to interpolate into the template | |
| idempotencyKey | No | Optional Idempotency-Key to make retries safe (avoids duplicate sends) |