Home/Email API/The CLI

The email CLI: send from your terminal

An email CLI sends and manages email from the command line: your terminal, a shell script, a CI pipeline, or a cron job. No SMTP setup, no local mail server, no HTTP client to write.

Verified By George Hartley, Co-founder · Updated July 20, 2026

What an email CLI is

An email CLI is a command-line tool for sending and managing email. Type a command, the email goes. Script the command, and email becomes part of your build, your deploy, your nightly job.

deploy.yml · last step
$ nitro send --to [email protected] \
--subject "Deploy #412 is live"
msg_2h81 accepted (148ms)
Deploy #412 is live
shell scripts CI pipelines cron jobs headless agents
If it can run a shell, it can send email.

The old way to send from a server was configuring a local mail agent and hoping port 25 stayed open. The CLI replaces that with an authenticated command against the same platform your application code uses. Same account, same templates, same delivery events, JSON out when you need to pipe it.

One boundary worth knowing: this is the sending side. If you want to read and triage an inbox from the terminal, that is a mailbox client, a different tool for a different job. An email CLI like this one exists to get mail out, reliably, from anything that can run a command.

Scripts, CI and cron

The places a CLI earns its keep are the places nobody wants to write an HTTP client: a deploy pipeline that mails the team on failure, a cron job that sends the nightly report, a shell script that alerts when disk fills up.

Terminalsend
nitrosend send --to "[email protected]" --subject "Deploy failed" --html "<p>Build 214 failed on main.</p>"

One line in a pipeline step. No SDK to install in the CI image, no SMTP credentials in your secrets manager, one API key in the environment.

Why agents run it

We shipped a CLI because agents run headless. Claude Code, Codex, and every terminal agent already live where the CLI lives. The same commands you type, an agent types faster.

This is the shape of the whole platform: the API for your code, the MCP server for conversational agents, and the CLI for the terminal, human or agent. The bar we hold ourselves to is thirty seconds from install to first email, because that is how fast an agent moves when the tool doesn't get in its way.

Inside the company, that bar is literally our north star metric: time from signup to first email sent. Every surface we ship, this one included, gets measured against it.

The CLI itself is an npm package, @nitrosend/cli, written in TypeScript like the MCP server and the AI SDK. One ecosystem, three surfaces, the same key.

Two things shipping around it finish the headless story. Setup is collapsing into a single command, npx @nitrosend/setup, which provisions the MCP connection and an API key the way Sentry's install wizard does, so an agent can take a fresh machine to a sent sandbox email without ever seeing a dashboard. And agents can now spawn their own send-and-receive inboxes on your domain, in beta, so an agent gets something like [email protected] to converse from without touching your Gmail or Microsoft setup.

Go deeper

Email from the terminal.

Simple pricing. Unlimited contacts.

Every plan includes full stack emailing: Flows, Newsletter Campaigns and Transactional Email, plus our NitroWheel LLM and all agent integrations (Claude, ChatGPT, Codex, Cursor and others). Pay for what you send, not who you store.

Free
$0
forever
  • Emails 8,000then 500/mo
  • Email types Transactional & Marketing
  • AI actions 20/mo
  • Contacts Free & Unlimited
  • Brands 1
  • Seats 1
Start free
Ultra
$100
per month
  • Emails 125,000/month
  • AI actions 5,000/mo
  • Brands 5
  • Seats 10 · Domains 3
  • Frontier AI Included
  • Dedicated IP Available
Get started
Enterprise
$300
per month
  • AI actions Unlimited
  • Unlimited brands & domains Included
  • SSO / SAML Included
  • 99.9% SLA Included
Get started

Free forever. No credit card required. See full comparison →