SMTP
Anything that can send email over SMTP can send through Herald without code changes: point its settings at Herald and use an API key as the password.
| Host | smtp.heraldmail.dev |
| Port | 465 (TLS from the start) or 587 (STARTTLS, required) |
| Username | herald |
| Password | an API key with the send scope |
| Limits | 50 recipients and 40 MB a message |
Herald only accepts authentication over TLS, so an app can’t send its key in the clear by mistake.
As a URL
Many apps take one setting:
SMTP_URL=smtps://herald:hrld_live_…@smtp.heraldmail.dev:465Nodemailer
import nodemailer from 'nodemailer'
const transport = nodemailer.createTransport({
host: 'smtp.heraldmail.dev',
port: 465,
secure: true,
auth: { user: 'herald', pass: process.env.HERALD_API_KEY },
})
await transport.sendMail({
from: 'Hallelo <hello@hallelo.church>',
to: 'ada@example.com',
subject: 'This Sunday',
text: 'Doors open at 10.',
})Herald’s own headers
Herald reads these, then removes them before the message goes on:
| Header | |
|---|---|
X-Herald-Stream | transactional (the default) or marketing: a Proclamation, with one-click unsubscribe |
X-Herald-Tags | name=value pairs, separated by commas, for the log and webhooks |
Everything else is handled as it is for the API: the same checks on the sender’s domain, the same quota and suppressions, and the same log and webhooks. A message Herald refuses is refused in the SMTP conversation, with the reason.