Catalog npm
PACKAGE EXPLORERView in registry

@0xshariq/email-mcp-server

npm

A MCP Server + CLI Tool that perform email operations

attachdeleteemailimapmcpsendserversmtp
Versions collected18
Direct dependencies21From release 2.0.1
Last observed21 Oct, 11:26 UTC

README

Current package documentation

Email MCP Server

Cross-platform email operations for MCP clients and CLI 🌍

A dual-purpose tool that works as:

  • 🔌 MCP Server: Email capabilities for Claude Desktop and MCP clients
  • ⚡ CLI Suite: 40+ commands for terminal email management

Universal compatibility: Works on Windows, macOS, Linux, and WSL with Gmail, Outlook, Yahoo, and any IMAP/SMTP providers.

✨ Features Overview

📧 Basic Operations: Send, read, get, delete emails | Mark read/unread
🔍 Advanced Features: Search, forward, reply, bulk operations | Draft & schedule
👥 Contact Management: Add, update, search, organize contacts by groups
🌐 Cross-Platform: Works identically on all platforms and terminals

🚀 Zero-Configuration Installation

🎯 One Command - Complete Setup:

npm install -g @0xshariq/email-mcp-server
# OR
pnpm install -g @0xshariq/email-mcp-server

✨ What Happens Automatically:

  • ✅ Detects your platform (Windows/macOS/Linux/WSL)
  • ✅ Creates 40+ command shortcuts globally
  • ✅ Configures system PATH automatically
  • ✅ Tests installation and provides setup guide
  • ✅ Ready to use immediately - no manual steps!

🎬 Getting Started:

# Set up your email (one-time only):
email-setup

# Start sending emails:
email-send "user@example.com" "Hello" "Your message"

# Explore all commands:
email-cli --help

📖 Complete Installation Guide

⚙️ Configuration

🔧 The MCP server and CLI share the same environment configuration!

Local Development (Both Server & CLI)

# Copy and edit .env file
cp .env.example .env
nano .env  # Add your credentials

Global Installation (CLI)

Configure environment variables in your shell profile:

Linux: Add to ~/.bashrc

export EMAIL_USER="your-email@gmail.com"
export EMAIL_PASS="xxxx-xxxx-xxxx-xxxx"
export SMTP_HOST="smtp.gmail.com"
export SMTP_PORT="587"
export IMAP_HOST="imap.gmail.com"
export IMAP_PORT="993"

macOS: Add to ~/.zshrc (or ~/.bash_profile)

export EMAIL_USER="your-email@gmail.com"
export EMAIL_PASS="xxxx-xxxx-xxxx-xxxx"
# ... (same as Linux)

Windows: Set System Environment Variables

  • Press Win + X → System → Advanced system settings
  • Environment Variables → Add each variable

Quick Example (Gmail)

EMAIL_USER=your-email@gmail.com
EMAIL_PASS=xxxx-xxxx-xxxx-xxxx  # App Password (not regular password)
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
IMAP_HOST=imap.gmail.com
IMAP_PORT=993

📖 Complete Configuration Guide - Detailed setup for all platforms and providers

Setup Requirements:

  1. Enable 2FA on your email provider
  2. Generate App Password
  3. Configure environment variables (locally or globally)

📋 Supports: Gmail, Outlook, Yahoo, and any IMAP/SMTP provider

💻 Usage

As MCP Server

npm start  # Starts MCP server for Claude Desktop

As CLI Tool (Cross-Platform)

# Works identically on Windows, macOS, Linux, WSL
email-send "user@example.com" "Subject" "Message"
email-read 10
contact-add "John Doe" "john@example.com" "work"
email-search --from "boss@company.com" --unread

All 40+ commands work the same across all platforms!

📚 Documentation

Complete documentation for all features and platforms:

📖 Core Documentation

DocumentDescription
Configuration GuideComprehensive environment setup for CLI and MCP server (local and global)
Installation GuideCross-platform installation instructions (Windows, macOS, Linux, WSL)
CLI ReferenceComplete reference for all 40+ CLI commands with examples
CLI UsageTop-level CLI usage and setup commands
Commands ReferenceDetailed command documentation with options and examples

🔧 Technical Documentation

DocumentDescription
ArchitectureSystem architecture, data models, and design decisions
TroubleshootingCommon issues and solutions for all platforms
Windows GuideWindows-specific installation and configuration
Publishing GuidePackage publishing and versioning strategy
Restructure Summaryv2.0 TypeScript migration details

🚀 Quick Start Guides

First Time Setup:

  1. Installation: INSTALL.md
  2. Configuration: CONFIGURATION.md
  3. First Commands: CLI_REFERENCE.md

Having Issues?

Development & Contributing:

🎯 By Use Case

As CLI User:

As MCP Server User:

As Developer:

MCP Server Integration

When running as an MCP server, all email operations are available as structured tools for Claude Desktop and other MCP clients.

Available Tools:

  • Email operations: send, read, search, forward, reply, delete
  • Contact management: add, update, search, organize
  • Bulk operations: batch sending, scheduling, drafts

Usage in Claude Desktop:

{
  "to": "user@example.com", 
  "subject": "Hello",
  "body": "Message from Claude!"
}

📖 Configuration: See CONFIGURATION.md

🔐 Security & Best Practices

  • Use App Passwords (not regular passwords)
  • Keep .env secure (never commit to git)
  • Respect rate limits for bulk operations
  • Use HTTPS/TLS for all connections

🛠️ Development & Contributing

Quick Development Setup:

git clone https://github.com/0xshariq/email-mcp-server.git
cd email-mcp-server
npm install          # Install dependencies
npm run build        # Compile TypeScript
npm link             # Test locally

Project Structure:

email-mcp-server/
├── cli/            # CLI implementation (Commander.js)
├── server/         # MCP server implementation
├── src/lib/        # Shared email & contact services
├── dist/           # Compiled JavaScript
└── docs/           # Complete documentation

Key Technologies:

  • TypeScript 5.8+ with strict mode
  • Commander.js 14+ for CLI
  • Nodemailer 7+ for SMTP
  • IMAP-Simple 5+ for IMAP
  • MCP SDK 1.15+ for server

Documentation for Developers:

Contributing: Fork → Branch → PR. See Contributing Guidelines

📞 Support & Resources

Issues & Questions:

Documentation by Topic:

All Documentation: See docs/ folder for complete guides

📄 License

MIT License - see LICENSE file for details.


🌟 Star this repo if it helps you manage emails efficiently across platforms!

Version: 2.0.0
Last Updated: December 20, 2025

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Versions 18

Collected releases
VersionPublishedDirect dependenciesOpen version
2.0.1Registry latest12 Jan 202621
2.0.020 Dec 202521
1.7.111 Oct 202511
1.7.011 Oct 202511
1.6.14 Oct 202510
1.6.03 Oct 202510
1.5.23 Oct 202510
1.5.13 Oct 202510
1.5.03 Oct 202510
1.4.03 Oct 202510
1.3.13 Oct 202510
1.3.02 Oct 202510
1.2.22 Oct 202510
1.2.12 Oct 202510
1.2.02 Oct 202510
1.1.12 Oct 20259
1.1.01 Oct 20259
1.0.01 Oct 20259

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Repository

PENDING
0xshariq/email-mcp-server

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 11:26 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:b0c3dff92a326dec7c57d33f43eb74d2664c9277f8cd260dcf5e1406879e349f