Docs

CLI

@irisend/cli is a local dev inbox and hot-reloading template preview for the sandbox email provider. Nothing it sends reaches AWS SES. Usage reference.

InstallcURL
npm install -g @irisend/cli
# or run without installing:
npx @irisend/cli dev

irisend dev — tail captured sends

Polls /dev/inbox on your Irisend server, prints each newly captured send, and serves a local preview UI at http://localhost:4400 — a list of captures with a sandboxed HTML preview and Text/Headers tabs, live-updated over SSE. Your API key is only ever sent to --api-url; the preview page's browser JavaScript never sees it. If the target server isn't running in sandbox mode, /dev/inbox 404s and the CLI exits immediately instead of polling forever.

TerminalcURL
irisend dev --api-url http://localhost:3001 --api-key $IRISEND_API_KEY
OutputcURL
[irisend dev] watching http://localhost:3001/dev/inbox — 2 existing capture(s)
[irisend dev] local preview: http://localhost:4400
[14:32:05] Acme <[email protected]> -> [email protected]: Welcome to Acme
FlagDefault
--api-urlhttp://localhost:3001 (or $IRISEND_API_URL)
--api-key$IRISEND_API_KEY
--port4400

irisend dev --template — hot-reloading template preview

Renders a local .html file (optionally with a JSON data file) and reloads the browser whenever either file changes. Variables use the same brace convention as broadcast personalization: {{{var}}} substitutes the raw value, {{var}} HTML-escapes it first; a key missing from the data file renders as an empty string.

TerminalcURL
irisend dev --template welcome.html --data vars.json --port 4400
welcome.htmlhtml
<!-- welcome.html -->
<h1>Welcome, {{{first_name}}}!</h1>
<p>Your plan: {{plan}}</p>
vars.jsonJSON
{ "first_name": "Jane", "plan": "Pro <3" }