Kimi’s quota had just reset, and I thought, since letting it sit unused would be a waste, I might as well turn Smailr’s (https://smailr.com) email service into an MCP. Once installed, clients like Claude Desktop, Cursor, Cherry Studio, and Cline can operate your mailbox directly using natural language. For example:
- “List the 5 most recent emails in my inbox”
- “Send an email to [email protected] from hello@mydomain”
- “How much of my storage quota have I used?”
The current implementation includes 23 tools, covering nearly all of Smailr’s API: creating, deleting, updating, and querying mailboxes; listing, viewing, searching, and sending emails; uploading attachments; contacts; folders; tags; as well as read-only interfaces for mail rules, signatures, quotas, and statistics.
The easiest part is logging in: you don’t need to manually create an API key in the settings page, since built-in NodeLoc OAuth lets you log in directly. Just run:
npx smailr-mcp auth
It will automatically open your browser and go through NodeLoc authorization. Once authorization is complete, paste the URL from the address bar back into the terminal (sample URL format: Smailr 邮箱…)(), and it will automatically create a scoped API key and print the MCP client configuration ready to paste. You never need to touch the settings page—the login, key creation, and configuration are all completed in one go.
A few other design considerations:
- Local-first: the server runs on your own computer via stdio, and the API key never passes through any third party
- Minimal dependencies: it only uses the official @modelcontextprotocol/sdk and zod, so the code is lightweight and easy to modify
Usage:
npx -y smailr-mcp
Then add the configuration in your MCP client (the README contains the complete JSON).
Known limitations, stated frankly: Smailr does not define a response schema, so tool outputs are passed through as raw JSON; contacts, folders, and tags only support listing and creation (Smailr simply has no update/delete APIs); there is no webhook push, so new mail must be retrieved by polling list_mails.
MIT licensed. Stars / issues / PRs are welcome.
Special thanks to @runoneall for the inspiration.
P.S. An MCP related to NodeLoc is currently in development—stay tuned.
Note:
After clicking authorize, seeing this is normal. You just need to paste the URL currently shown in the address bar—something like Smailr 邮箱…—back into your client.
