machin-herald

Run a command. Email its output. On a schedule.

A scheduled report mailer as one static machin binary — no Node, no template engine, no scheduler. Each target names a shell command; whatever it prints becomes the email body. The source owns the rendering; herald just delivers.

View on GitHub Powered by Resend →
$ machin-herald -c herald.json send --target hart-weekly
{"ok":true,"target":"hart-weekly","sent":true,"id":"899fdef1-...","bytes":2413}

Two decisions that keep it small

The source owns the rendering

herald never templates anything. Your command prints HTML or text and herald ships it — so anything is a report source: hart admin digest, df -h, a five-minute script.

No scheduler, on purpose

systemd timers and cron already do persistent, catch-up, logged scheduling correctly. herald is a one-shot send you point a timer at — OnCalendar= is your daily/weekly/monthly.

BYO key, no secrets in config

RESEND_API_KEY lives in the environment, never in the config file — so the config is safe to commit. --dry-run previews without sending.

Agent-first

JSON on stdout, structured errors on stderr, semantic exit codes. A non-zero command exit means nothing is sent — an agent can drive it blind and parse the result.

Config

{
  "from": "hart digest <digest@your-domain.tld>",
  "targets": [
    { "name": "hart-weekly",
      "to": ["you@your-domain.tld"],
      "subject": "hart — weekly digest",
      "command": "hart admin digest --days 7 | my-renderer",
      "format": "html" }
  ]
}

Schedule (systemd)

# herald-weekly.timer
[Timer]
OnCalendar=Mon 08:00
Persistent=true   # missed a run? fires on next boot
Built in machin (MFL) · part of the agent-first stack by Intrane · MIT.