POST /v1/emails
Provide a from address on a verified domain (or the shared onboarding domain in test mode), at least one recipient, a subject, and a body — html, text, or both. Or send a stored template with templateId + data and omit the subject and body.
Body parameters
The sender,
{ email, name? }. The email domain must be verified for this project (or the shared onboarding domain in test mode).One or more recipients, each
{ email, name? }. At least one is required.The subject line. Required unless
templateId is given.The HTML body. Provide
html, text, or both.The plain-text body. Recommended alongside
html for deliverability.Carbon-copy recipients.
Blind carbon-copy recipients.
Addresses to set in the
Reply-To header.Send a stored template by id or slug. With a template,
subject/html/text are optional and merge variables come from data.Merge variables for the template (
{{handlebars}} placeholders).Extra headers to set on the message, as a string-to-string map.
Labels for filtering and analytics, each
{ name, value }.Files to attach, each
{ filename, content, contentType? } where content is base64-encoded bytes.Schedule the send for a future time (ISO 8601). Omit to send immediately.
Headers
Make this POST safe to retry — the same key replays the original result for 24 hours, per project. See Idempotency & retries.
Names the sending project for account-wide keys (alias:
X-Drin-Sender). Project-scoped keys may omit it.Request
Response
202 Accepted — the message was queued. Track its lifecycle with GET /v1/emails/{id} or over webhooks.
202 Accepted
Test mode. The shared onboarding domain can only deliver to your own address. To email anyone from your own brand, verify a domain first.
