Skip to content

mailkite/mailkite-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MailKite

@mailkite/cli

Email for every product you ship — receive email as a webhook, send over a verified domain, give an AI agent its own inbox.
The official MailKite library for the command line.

Docs · Library guide · mailkite.dev · AI agents

npm

Read-only mirror. This repo is a generated, release-time mirror of the MailKite monorepo (the private source of truth) — development doesn't happen here. Install from npm and open issues against the MailKite docs.

Install

npx @mailkite/cli --help     # no install
npm i -g @mailkite/cli       # or install the `mailkite` binary globally

Quickstart

mailkite login --email you@example.com
mailkite domains add mail.myapp.ai      # then add the printed DNS records
mailkite domains verify <domainId>      # MX / SPF / DKIM / DMARC
mailkite webhook set <domainId> https://myapp.ai/hooks/mailkite
mailkite send --from hello@mail.myapp.ai --to you@example.com \
  --subject "It works" --html "<p>Hi from MailKite</p>"
mailkite messages tail                  # watch inbound arrive

Commands

Full command reference: https://mailkite.dev/docs/cli. Common flows:

mailkite login --email you@example.com
mailkite domains add mail.myapp.ai      # then add the printed DNS records
mailkite domains verify <domainId>      # MX / SPF / DKIM / DMARC
mailkite webhook set <domainId> https://myapp.ai/hooks/mailkite
mailkite send --from hello@mail.myapp.ai --to you@example.com \
  --subject "It works" --html "<p>Hi from MailKite</p>"
mailkite messages tail                  # watch inbound arrive

Use it from an AI agent — MCP + Agent connectors

MailKite speaks the Model Context Protocol: every API method is a tool your AI assistant (Claude, Cursor, …) can call — send mail, manage domains, search the docs, and give an agent its own inbox. Full guide: https://mailkite.dev/docs/ai-agents.

Hosted (recommended) — one-click OAuth, no key to copy:

claude mcp add --transport http mailkite https://mcp.mailkite.dev/mcp

In Claude Code you can also install the plugin:

/plugin marketplace add mailkite/claude-code
/plugin install mailkite@mailkite

Any chat/UI agent: "Add the MCP server at https://mcp.mailkite.dev/mcp and authenticate in the browser when prompted."

Local (static key, offline / CI):

{ "mcpServers": { "mailkite": { "command": "npx", "args": ["-y", "@mailkite/mcp"], "env": { "MAILKITE_API_KEY": "mk_live_…" } } } }

Give an agent its own inbox. Route inbound mail to a built-in inbox agent (the agent route action) and it answers, files, or escalates on its own — see https://mailkite.dev/docs/ai-agents.

All MailKite libraries

Same contract, every language — pick the one for your stack (full list: https://mailkite.dev/docs/libraries):

Library Repo Distribution
MailKite for Node.js mailkite-node npm
MailKite for Python mailkite-python PyPI
MailKite for Ruby mailkite-ruby RubyGems
MailKite for Java mailkite-java Maven Central
MailKite for PHP mailkite-php Packagist
MailKite for Go mailkite-go Go modules
@mailkite/cli (this repo) mailkite-cli npm
@mailkite/mcp mailkite-mcp npm
@mailkite/client mailkite-js npm
@mailkite/expo mailkite-expo npm
MailKiteClient mailkite-swift Swift Package Manager
dev.mailkite:mailkite-client mailkite-kotlin Maven Central
mailkite_client mailkite-flutter pub.dev

Docs & links

Generated from the shared MailKite API contract. © MailKite.

About

MailKite CLI (@mailkite/cli). Read-only mirror (sdks/cli). Do not edit here.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors