by ZilongXue
ClaudePost is a Model Context Protocol (MCP) server that integrates with Claude Desktop to provide a seamless email management interface. It allows users to interact with their emails (search, read, compose, send) using natural language conversations directly within Claude.
ClaudePost is a Model Context Protocol (MCP) server that integrates with Claude Desktop to provide a seamless email management interface. It allows users to interact with their emails (search, read, compose, send) using natural language conversations directly within Claude.
To use ClaudePost, you need Python 3.12+, a Gmail account (or other email provider), and the Claude Desktop application. Setup involves cloning the repository, installing dependencies with uv
, configuring a .env
file with your email credentials (using an app-specific password for Gmail for security), and finally, configuring Claude Desktop by adding a specific mcpServers
entry in its claude_desktop_config.json
file. Once configured, the server runs automatically when Claude Desktop is launched, and you can interact with your emails through natural language commands within Claude.
ClaudePost is ideal for individuals who want to manage their emails efficiently using natural language. Specific use cases include:
Q: What are the prerequisites for using ClaudePost? A: Python 3.12 or higher, a Gmail account (or other email provider), and the Claude Desktop application. For Gmail, two-factor authentication and an app-specific password are required.
Q: How does ClaudePost handle security? A: It emphasizes using app-specific passwords instead of your main account password, especially for Gmail users, and handles email securely with TLS.
Q: Do I need to manually run the ClaudePost server? A: No, the server runs automatically through Claude Desktop. It starts when Claude launches and stops when Claude is closed.
Q: Can I send emails directly without confirmation? A: For security reasons, Claude will always show you the email details for confirmation before actually sending an email.
Q: Where can I find logs for debugging?
A: The application logs detailed information to email_client.log
for debugging and error messages.
A Model Context Protocol (MCP) server that provides a seamless email management interface through Claude. This integration allows you to handle emails directly through natural language conversations with Claude, supporting features like searching, reading, and sending emails securely.
Install uv:
# MacOS/Linux
curl -LsSf https://astral.sh/uv/install.sh | sh
# Remember to restart your terminal after installation
Clone and set up the project:
# Clone the repository
git clone https://github.com/ZilongXue/claude-post.git
cd claude-post
# Create and activate virtual environment
uv venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
# Install dependencies
uv pip install -e .
Create a .env
file in the project root:
EMAIL_ADDRESS=your.email@gmail.com
EMAIL_PASSWORD=your-app-specific-password
IMAP_SERVER=imap.gmail.com
SMTP_SERVER=smtp.gmail.com
SMTP_PORT=587
Configure Claude Desktop:
First, make sure you have Claude for Desktop installed. You can install the latest version here. If you already have Claude for Desktop, make sure it's updated to the latest version.
Open your Claude Desktop configuration file:
# MacOS
~/Library/Application Support/Claude/claude_desktop_config.json
# Create the file if it doesn't exist
mkdir -p ~/Library/Application\ Support/Claude
touch ~/Library/Application\ Support/Claude/claude_desktop_config.json
Add the following configuration:
{
"mcpServers": {
"email": {
"command": "/Users/username/.local/bin/uv",
"args": [
"--directory",
"/path/to/claude-post/src/email_client",
"run",
"email-client"
]
}
}
}
Replace /Users/username
and /path/to/claude-post
with your actual paths.
After updating the configuration, restart Claude Desktop for the changes to take effect.
The server runs automatically through Claude Desktop:
You can interact with your emails using natural language commands. Here are some examples:
Note: For security reasons, Claude will always show you the email details for confirmation before actually sending.
claude-post/
├── pyproject.toml
├── README.md
├── LICENSE
├── .env # Not included in repo
├── .python-version # Python version specification
└── src/
└── email_client/
├── __init__.py
├── __main__.py
└── server.py # Main implementation
.env
fileThe application logs detailed information to email_client.log
. Check this file for debugging information and error messages.
This project is licensed under the MIT License - see the LICENSE file for details.
Reviews feature coming soon
Stay tuned for community discussions and feedback