molt-mcp
Provides LLMs with access to molt-md, an encrypted markdown document hosting service, for managing and reading secure knowledge bases. It enables users to create, update, and organize encrypted documents into workspaces with full version control and end-to-end encryption.
README
molt-mcp
A Model Context Protocol (MCP) server that provides LLM access to molt-md, an encrypted markdown document hosting service. Turn your markdown files into an LLM-accessible knowledge base by uploading them to molt-md and accessing them through this MCP server. Your AI assistant can read, update, and manage encrypted markdown documents organized in workspaces.
Features
- Markdown → MCP Server - Organize your markdown files into LLM-accessible storage with workspaces (free while in beta)
- Full API Coverage - Every molt-md endpoint exposed as an MCP tool
- Encrypted Storage - End-to-end encryption with AES-256-GCM
- Read/Write Key Support - Permission enforcement via the API's dual-key model
- Workspace Management - Bundle and organize multiple documents
- Partial Fetches - Efficient document previews with line-limited reads
- Version Control - Optimistic concurrency control with ETag support
Installation
Install directly from GitHub using uvx:
uvx --from git+https://github.com/bndkts/molt-md-mcp molt-mcp
Or install from source for development:
git clone https://github.com/bndkts/molt-md-mcp.git
cd molt-md-mcp
uv pip install -e .
Configuration
Claude Desktop
Add to your Claude Desktop config file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"molt-md": {
"command": "uvx",
"args": ["--from", "git+https://github.com/bndkts/molt-md-mcp", "molt-mcp"],
"env": {
"MOLT_API_KEY": "your-api-key-here",
"MOLT_WORKSPACE_ID": "your-workspace-id-here"
}
}
}
}
Environment Variables
MOLT_API_KEY(required) - Your molt-md write key or read key (obtained by creating a document)MOLT_WORKSPACE_ID(optional) - Access documents through a specific workspaceMOLT_BASE_URL(optional) - API base URL (defaults tohttps://api.molt-md.com/api/v1; usehttp://localhost:8000/api/v1for local development)
Permission Model
The server passes your configured key to the molt-md API on every request:
- Write key → All operations succeed (read + create + update + delete)
- Read key → Read operations succeed; write operations return
403 Forbiddenfrom the API
Available Tools
Read-Only Tools (Available with both key types)
health_check- Check if the molt-md API is availableget_metrics- Get database statistics (document and workspace counts)read_doc- Read a document's decrypted content- Supports partial fetches with
linesparameter - Returns JSON with metadata or plain markdown
- Supports partial fetches with
read_workspace- Read a workspace's content (name and entries)- Supports preview generation with
preview_linesparameter
- Supports preview generation with
Write Tools (Require write key)
Document Operations
create_doc- Create a new encrypted document- Returns document ID, write key, and read key
update_doc- Replace a document's entire content- Supports optimistic locking with
if_match(version ETag)
- Supports optimistic locking with
append_doc- Append content to the end of a document- Supports optimistic locking with
if_match
- Supports optimistic locking with
delete_doc- Permanently delete a document
Workspace Operations
create_workspace- Create a new workspace to bundle documents- Returns workspace ID, write key, and read key
update_workspace- Replace a workspace's content (name and entries)- Supports optimistic locking with
if_match
- Supports optimistic locking with
delete_workspace- Permanently delete a workspace- Does not delete referenced documents
Usage Examples
Basic Document Operations
User: Create a new document with the title "Meeting Notes"
Assistant: [Uses create_doc tool] → Returns doc ID and keys
User: Read that document
Assistant: [Uses read_doc tool with the doc ID]
User: Append a new section to the document
Assistant: [Uses append_doc tool]
Workspace Management
User: Create a workspace called "Project Alpha" with these two documents
Assistant: [Uses create_workspace tool with document IDs and keys]
User: Show me a preview of all documents in the workspace
Assistant: [Uses read_workspace with preview_lines=1]
Partial Fetches for Efficiency
User: Show me just the title of document xyz
Assistant: [Uses read_doc with lines=1 and as_markdown=true]
Development
Setup
# Clone the repository
git clone https://github.com/bndkts/molt-md-mcp.git
cd molt-md-mcp
# Install dependencies
uv pip install -e .
# Run the server
molt-mcp
Testing
With local molt-md API:
# Start the molt-md API server first (in another terminal)
cd /path/to/molt-md
cargo run # or your preferred method
# Create a test document to get keys
curl -X POST http://localhost:8000/api/v1/docs \
-H "Content-Type: application/json" \
-d '{"content": "# Test Document"}'
# Save the write_key and id from the response
# Run the MCP server
export MOLT_BASE_URL="http://localhost:8000/api/v1"
export MOLT_API_KEY="your-write-key-here"
npx @modelcontextprotocol/inspector molt-mcp
With production molt-md API:
# Create a test document to get keys
curl -X POST https://api.molt-md.com/api/v1/docs \
-H "Content-Type: application/json" \
-d '{"content": "# Test Document"}'
# Save the write_key from the response
# Run the MCP server
export MOLT_API_KEY="your-write-key-here"
npx @modelcontextprotocol/inspector molt-mcp
Security Notes
- Never commit API keys to version control
- Keys are shown only once during document/workspace creation - save them securely
- Read keys can be safely shared for read-only collaborators
- Write keys provide full access - share only with trusted editors
- Lost keys cannot be recovered - the content becomes permanently inaccessible
Architecture
This is a thin wrapper around the molt-md REST API:
- FastMCP handles the MCP protocol and tool registration
- httpx makes async HTTP requests with connection pooling
- Environment config provides API key and optional workspace context
- UUID validation and ETag formatting ensure correct API usage
Links
- molt-md: https://molt-md.com
- MCP Specification: https://modelcontextprotocol.io
- FastMCP: https://github.com/jlowin/fastmcp
License
MIT License - see LICENSE file for details
Contributing
Contributions are welcome! Please open an issue or pull request on GitHub.
Built with ❤️ for the Model Context Protocol ecosystem
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。