ND

non-dirty/imap-mcp

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

58 stars 24 forks 质量 44 趋势 13

nondirty/imap-mcp 是从 https://github.com/non-dirty/imap-mcp. 导入的 MCP 服务器候选

概览

nondirty/imap-mcp 是从 https://github.com/non-dirty/imap-mcp. 导入的 MCP 服务器候选

概述(AI 翻译)

一个模型上下文协议(MCP)服务器,使AI助手能够通过交互检查邮件、处理消息并学习用户偏好。

概述

该项目实现了一个与IMAP邮件服务器接口的MCP服务器,提供以下功能:

  • 电子邮件浏览和搜索
  • 邮件组织(移动、标记、标记)
  • 电子邮件写作及回复
  • 交互式邮件处理与用户偏好学习
  • 自动邮件摘要和分类
  • 支持多个IMAP提供商

IMAP MCP 服务器设计用于与 Claude 或其他兼容 MCP 的助手配合,使其作为智能邮件助手,随着时间学习您的偏好。

特色

  • 电子邮件认证:通过多种认证方法安全访问IMAP服务器
  • 电子邮件浏览:列出带有过滤选项的文件夹和邮件
  • 电子邮件内容:阅读包括文本、HTML和附件在内的消息内容
  • 电子邮件操作:移动、删除、标记为已读/未读、标记邮件
  • 电子邮件作文:起草并保存格式良好的回复
  • 支持纯文本和HTML回复

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

IMAP MCP Server

A Model Context Protocol (MCP) server that enables AI assistants to check email, process messages, and learn user preferences through interaction.

Overview

This project implements an MCP server that interfaces with IMAP email servers to provide the following capabilities:

  • Email browsing and searching
  • Email organization (moving, tagging, marking)
  • Email composition and replies
  • Interactive email processing and learning user preferences
  • Automated email summarization and categorization
  • Support for multiple IMAP providers

The IMAP MCP server is designed to work with Claude or any other MCP-compatible assistant, allowing them to act as intelligent email assistants that learn your preferences over time.

Features

  • Email Authentication: Secure access to IMAP servers with various authentication methods
  • Email Browsing: List folders and messages with filtering options
  • Email Content: Read message contents including text, HTML, and attachments
  • Email Actions: Move, delete, mark as read/unread, flag messages
  • Email Composition: Draft and save replies to messages with proper formatting
    • Support for plain text and HTML replies
    • Reply-all functionality with CC support
    • Proper threading with In-Reply-To and References headers
    • Save drafts to appropriate folders
  • Search: Basic search capabilities across folders
  • Interaction Patterns: Structured patterns for processing emails and learning preferences (planned)
  • Learning Layer: Record and analyze user decisions to predict future actions (planned)

Current Project Structure

The project is currently organized as follows:

.
├── examples/              # Example configurations
│   └── config.yaml.example
├── imap_mcp/              # Source code
│   ├── __init__.py
│   ├── config.py          # Configuration handling
│   ├── imap_client.py     # IMAP client implementation
│   ├── models.py          # Data models
│   ├── resources.py       # MCP resources implementation
│   ├── server.py          # Main server implementation
│   └── tools.py           # MCP tools implementation
├── tests/                 # Test suite
│   ├── __init__.py
│   └── test_models.py
├── INSTALLATION.md        # Detailed installation guide
├── pyproject.toml         # Project configuration
└── README.md              # This file

Getting Started

Prerequisites

  • Python 3.8 or higher
  • An IMAP-enabled email account (Gmail recommended)
  • uv for package management and running Python scripts

Installation

  1. Install uv if you haven’t already:

    curl -LsSf https://astral.sh/uv/install.sh | sh
    
  2. Clone and install the package:

    git clone https://github.com/non-dirty/imap-mcp.git
    cd imap-mcp
    uv venv
    source .venv/bin/activate  # On Windows: .venv\Scripts\activate
    uv pip install -e ".[dev]"
    

Gmail Configuration

  1. Create a config file:
在 GitHub 查看完整 README

安装

This server does not publish a one-line install command.

Open the repository installation guide 新手?先看 mcpskill.org 教程 →