A Python wrapper for the fetch-clean-markdown-mcp MCP server — fetches URLs and returns clean, LLM-optimized Markdown
Project description
fetch-clean-markdown-mcp
An MCP (Model Context Protocol) server that fetches URLs and returns clean, LLM-optimized Markdown.
Features
- Clean extraction — Strips HTML, scripts, and boilerplate from any public URL
- Security hardened — SSRF protection, redirect validation, prompt injection sanitization, payload size limits
- Edge deployed — Runs on Cloudflare Workers for global low-latency access
- Locally runnable — Can also run via stdio for local MCP client integration
Usage
Configuration for Cline / MCP clients
Add to your cline_mcp_settings.json:
{
"mcpServers": {
"fetch-clean-markdown-mcp": {
"command": "node",
"args": ["dist/local.js"],
"env": {}
}
}
}
Or use the npm package globally:
{
"mcpServers": {
"fetch-clean-markdown-mcp": {
"command": "npx",
"args": ["fetch-clean-markdown-mcp"],
"env": {}
}
}
}
Remote (Cloudflare Worker)
https://fetch-clean-markdown-mcp.yourbuttstinks69420.workers.dev
Tool
fetch_clean_markdown
CRITICAL: Use this tool to extract clean, readable text/markdown from any public URL.
Input:
url(string, required) — The public web URL to fetch
Returns:
- Clean Markdown text with HTML stripped, injection sanitization applied, and size-limited to 512 KB
Local Development
# Install dependencies
npm install
# Build
npm run build
# Run locally
npm start
# Run with hot-reload
npm run start:dev
Deploy to Cloudflare
npx wrangler login
npm run deploy
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fetch_clean_markdown_mcp-1.0.0.tar.gz.
File metadata
- Download URL: fetch_clean_markdown_mcp-1.0.0.tar.gz
- Upload date:
- Size: 4.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f77e2ebd12a04497011c88ab1883d9315dccd624341b3cd45e170b0c786e4458
|
|
| MD5 |
4f31874e342d8ced0be4056c80071847
|
|
| BLAKE2b-256 |
d314b66ded01a7fa9ea4658a82df335ddb9cb72c3f6d52f4084f567b0df224e6
|
File details
Details for the file fetch_clean_markdown_mcp-1.0.0-py3-none-any.whl.
File metadata
- Download URL: fetch_clean_markdown_mcp-1.0.0-py3-none-any.whl
- Upload date:
- Size: 5.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
92d61b98a82507bfbdb2bad4f61f6707ff8184970a06f8936ced015f244ef894
|
|
| MD5 |
f6cde281ee74348c871c8f1ee4812d6f
|
|
| BLAKE2b-256 |
99283716751c60e869d90e7ac695cd81400cdb736d0e9c4969034b38ffdc8b51
|