CLI

sendneo is a single file that needs nothing but Python 3.8 or newer — no packages to install. It talks to the same API as your code, with the same keys.

Install

curl -fsSL https://sendneo.yorkermedia.com/cli/sendneo -o sendneo && chmod +x sendneo
sudo mv sendneo /usr/local/bin/      # optional: put it on your PATH
sendneo --version

Log in

sendneo login                      # paste the key when asked; it is not echoed
printf %s "$KEY" | sendneo login   # or pipe it in, e.g. in CI
sendneo whoami

login checks the key, then saves it with the API address in ~/.config/sendneo/credentials (or $XDG_CONFIG_HOME/sendneo/credentials), readable only by you (mode 600). sendneo logout deletes the file.

Instead of logging in you can set environment variables; they win over the saved login:

Variable Meaning
SENDNEO_API_KEY The key to use (sn_live_… or sn_test_…).
SENDNEO_BASE_URL The SendNeo address, if not https://sendneo.yorkermedia.com.

Send

sendneo send --from "Acme <hi@mail.acme.com>" --to ada@example.com \
  --subject "Your receipt #4821" --html-file receipt.html --text "Thanks for your order." \
  --attach invoice.pdf --tag order=4821 --idempotency-key order-4821-receipt
Option API field
--from ADDRESS from (required)
--to, --cc, --bcc, --reply-to to, cc, bcc, reply_to — repeat the option or separate with commas
--subject TEXT subject
--text TEXT, --html HTML text, html
--text-file PATH, --html-file PATH the body from a file; - reads standard input
--template ID, --var NAME=VALUE template_id and variables
--tag NAME=VALUE tags (repeat)
--header 'Name: value' headers (repeat)
--attach PATH attachments: the file, base64-encoded, with its type guessed from the name (10 MB in total)
--schedule ISO8601 scheduled_at, e.g. 2026-10-20T09:00:00Z (at most 30 days ahead)
--idempotency-key KEY the Idempotency-Key header: a retry with the same key never sends twice

send prints the new email's id. With a test key nothing reaches an inbox; see Test mode.

Everything else

sendneo emails list                 # your newest emails
sendneo emails get <id>             # status, recipients, tags
sendneo emails cancel <id>          # a scheduled email that has not gone out
sendneo domains list
sendneo domains add mail.example.com     # prints the DNS records to publish
sendneo domains verify mail.example.com
sendneo domains get mail.example.com
sendneo events --email <id>         # one email's timeline; also --type bounced,complained --after N --limit N
sendneo validate ada@gmial.com      # typo, disposable, role and mail-server checks
sendneo usage                       # emails this month and today, and the limits

Add --json to any command for the API's raw JSON, for scripts and jq.

Exit codes

Code Meaning
0 Done.
1 The API refused the request; the message says why (for example domain_not_verified).
2 The command or its options are wrong.
3 No API key is configured, or SendNeo rejected the key.
4 SendNeo could not be reached (network, DNS or TLS).