@trishchuk/mcp-fetch-server
@trishchuk/mcp-fetch-server
Ein leistungsstarker Model Context Protocol (MCP) Server, der ein gegen Bots resistentes fetch-Werkzeug für KI-Agenten (Claude Code, Claude Desktop, Cursor, Windsurf, Cline, Antigravity usw.) bereitstellt.
Angetrieben von @trishchuk/fetch – einem nativen HTTP-Client im Stil von curl-impersonate, der präzise echte Browser TLS (JA3/JA4, ClientHello) und HTTP/2-Fingerabdrücke nachahmt.
🚀 Warum dieser Server?
Standard-Node.js/Undici HTTP-Clients werden von modernen Bot-Schutzsystemen (Cloudflare Turnstile / Under Attack Mode, DataDome, PerimeterX / HUMAN, Akamai, Kasada, AWS WAF) sofort erkannt und blockiert.
Darüber hinaus scheitern standardmäßige MCP-Fetching-Werkzeuge oft an großen Nutzlasten oder sprengen die LLM-Token-Kontexte.
@trishchuk/mcp-fetch-server löst beide Probleme:
Realistische Browser-Imitation: Repliziert exakte Cipher-Suites, TLS-Erweiterungen, ALPN-Reihenfolge und HTTP/2-Einstellungsrahmen moderner Browser (Chrome, Safari, Firefox).
LLM-kontextsichere Kürzung: Streamt und begrenzt Antwortkörper auf 2 MB (
maxResponseBytes). Zu große Seiten werden sauber gekürzt und mit"truncated": truemarkiert, anstatt mit Fehlern abzustürzen.Zustandsbehaftete Sitzungen: Behält Cookies, Login-Zustände und Verbindungspools über mehrere Agenten-Werkzeugaufrufe hinweg mit dem Parameter
sessionbei.Intelligente Kodierung: Erkennt automatisch MIME-Typen und gibt sauberen UTF-8-Text für HTML/JSON/XML oder Base64 für Binärdateien (Bilder, PDFs, Dokumente) zurück.
Related MCP server: SteadyFetch
✅ Voraussetzungen
Node.js >= 24 – erforderlich von
@trishchuk/fetch.Vorgefertigte native Binärdateien werden für macOS (arm64, x64), Linux (x64/arm64, glibc und musl) und Windows (x64) ausgeliefert. Andere Plattformen werden vom zugrunde liegenden Client nicht unterstützt.
📦 Installation & Einrichtung
Option 1: Ausführen mit npx (Keine Installation erforderlich)
Sie können den Server direkt via npx ausführen:
npx -y @trishchuk/mcp-fetch-serverOption 2: Globale oder lokale Installation
# Global
npm install -g @trishchuk/mcp-fetch-server
# Or clone & install locally
git clone https://github.com/x51xxx/mcp-fetch-server.git
cd mcp-fetch-server
npm install⚙️ MCP-Client-Konfiguration
Claude Code
Direkt über die CLI hinzufügen:
# Using npx (recommended)
claude mcp add fetch -- npx -y @trishchuk/mcp-fetch-server
# Or using local path
claude mcp add fetch -- node /path/to/mcp-fetch-server/src/index.jsClaude Desktop
Zu Ihrer claude_desktop_config.json hinzufügen:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.jsonLinux:
~/.config/Claude/claude_desktop_config.json
{
"mcpServers": {
"fetch": {
"command": "npx",
"args": ["-y", "@trishchuk/mcp-fetch-server"]
}
}
}Cursor / Windsurf / Antigravity (.mcp.json)
Erstellen oder aktualisieren Sie .mcp.json in Ihrem Arbeitsbereich:
{
"mcpServers": {
"fetch": {
"command": "npx",
"args": ["-y", "@trishchuk/mcp-fetch-server"]
}
}
}🛠️ Werkzeugreferenz: fetch
Eingabeparameter
Parameter | Typ | Standard | Beschreibung |
|
| erforderlich | Ziel-absolute URL (z. B. |
|
|
| HTTP-Methode ( |
|
|
| Anfrage-Header als Schlüssel-Wert-Paare ( |
|
|
| Anforderungskörper, gesendet als UTF-8-Zeichenkette (JSON, formularcodiert, Rohtext). |
|
|
| Browser-Fingerabdruck-Voreinstellung (z. B. |
|
|
| Deklariertes Betriebssystem: |
|
|
| Proxy-URL: |
|
|
| Sitzungs-ID zur gemeinsamen Nutzung von Client-Verbindungen und Cookie-Jars über mehrere Aufrufe. |
|
|
| Benutzerdefiniertes DNS-Pinning (z. B. |
|
|
| Umleitungsmodus: |
|
|
| Erzwungene Protokollversion: |
|
|
| Minimale TLS-Version: |
|
|
| Maximale TLS-Version: |
|
|
| Gesamtzeitüberschreitung der Anfrage in Millisekunden. |
|
|
| Körperlimit in Bytes (maximal 2 MB). Antworten, die dies überschreiten, werden sicher gekürzt. |
|
|
| Format der Körperrückgabe: |
Antwortschemata
1. Erfolgreicher HTTP-Austausch
Jeder abgeschlossene HTTP-Transfer gibt ein standardmäßiges JSON-Ergebnis zurück (einschließlich 404, 500 oder 3xx unter redirect: "manual"):
{
"status": 200,
"statusText": "OK",
"ok": true,
"url": "https://example.com/data",
"redirected": false,
"headers": {
"content-type": "application/json; charset=utf-8",
"cache-control": "max-age=3600"
},
"bodyEncoding": "text",
"body": "{\"message\": \"Hello world\"}",
"truncated": false
}2. Netzwerk-/Transportfehler
Wenn die Netzwerkverbindung fehlschlägt, eine Zeitüberschreitung auftritt oder die URL ungültig ist, gibt das Werkzeug isError: true zurück:
{
"error": true,
"code": "TIMEOUT",
"message": "failed to read response body: request or response body error: operation timed out"
}💡 Verwendungsbeispiele für Agenten
1. Bot-Erkennung auf geschütztem Ziel umgehen
{
"url": "https://protected-site.com/products",
"impersonate": "chrome_147",
"platform": "macos",
"headers": {
"Accept-Language": "en-US,en;q=0.9"
}
}2. Mehrschrittiges Scraping mit persistenter Sitzung (Cookie-Jar)
// Step 1: Login / Obtain Session Cookie
{
"url": "https://example.com/api/login",
"method": "POST",
"session": "agent-crawler-01",
"headers": { "Content-Type": "application/json" },
"body": "{\"user\":\"admin\",\"password\":\"secret\"}"
}
// Step 2: Access protected resource (session cookies automatically preserved)
{
"url": "https://example.com/api/dashboard",
"session": "agent-crawler-01"
}3. Routen über einen SOCKS5-Proxy
{
"url": "https://geo-restricted.example.com",
"proxy": "socks5://user:pass@proxy.example.com:1080",
"impersonate": "safari_26"
}4. Abrufen von Binär-Assets (Bilder, PDFs)
{
"url": "https://example.com/report.pdf",
"encoding": "base64"
}5. DNS-Pinning für SSRF-sichere Aufnahme
{
"url": "https://internal-origin.example.com/feed",
"resolve": {
"internal-origin.example.com": "192.0.2.42"
},
"redirect": "manual"
}🔬 Impersonation-Voreinstellungen & Fingerabdrücke
@trishchuk/mcp-fetch-server unterstützt eine breite Palette von Browser-Fingerabdrücken:
Chrome:
"chrome_100"…"chrome_149"(z. B."chrome_147","chrome_131","chrome_116")Edge:
"edge_101"…"edge_148"Opera:
"opera_116"…"opera_131"Firefox:
"firefox_109","firefox_133","firefox_147"…, plus"firefox_private_136"und"firefox_android_135"Safari:
"safari_15.3"…"safari_26.4", plus iOS/iPad-Varianten ("safari_ios_26","safari_ipad_26")OkHttp (Android-Apps):
"okhttp_3.9"…"okhttp_5"Dynamisch:
"random","weighted_random"(rotiert Fingerabdrücke automatisch, prosessionfestgelegt)
Versionsnummern verwenden Unterstriche (chrome_147, nicht chrome147). Ein unbekannter Name schlägt sofort mit einem InvalidArg-Fehler fehl, der alle akzeptierten Varianten auflistet.
🧪 Entwicklung
npm install
npm start # run the server over stdio
npm test # end-to-end smoke tests, no network required
npm run format # format with Biome
npm run lint # lint with Biome
npm run check # format + lint check, also run before publishDie Tests starten den echten Server über stdio und steuern ihn mit einem MCP-Client gegen einen lokalen HTTP-Server, wobei die Kürzung an der Grenze, Umleitungsmodi, HEAD, Base64-Körper, Zeitüberschreitungen und Transportfehler abgedeckt werden.
📄 Lizenz
MIT © Taras Trishchuk
Available Tools
1 toolfetchFetchA
HTTP fetch backed by @trishchuk/fetch: a curl-impersonate-style client that emulates a real browser TLS/HTTP2 fingerprint (JA3/JA4, ClientHello, ALPN) so requests are not flagged by fingerprint-based bot detection (Cloudflare, DataDome, PerimeterX, etc.) the way Node's default HTTP client is. Use it for GET/POST/etc. against sites that block or challenge plain scrapers.
Inputs: url (required), body, proxy, method, +12 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 1 tool
With only a single tool, there is no possibility of confusion with other tools. The tool's purpose is clearly described and distinct by default.
With only one tool, there is no pattern to judge. The name 'fetch' is simple and conventional, matching common HTTP client terminology, but the lack of a verb_noun convention is neutral.
A single tool for an HTTP fetch server is too minimal. Most similar servers would include additional tools for managing headers, cookies, or caching, making this feel under-scoped for its stated purpose of scraping.
The server only provides a basic fetch tool with no support for managing sessions, handling redirects, managing cookies, or performing other common HTTP operations. This leaves significant gaps for any realistic scraping workflow.
Maintenance
Related MCP Connectors
Reliable web fetching for AI agents with retry, circuit breaker, caching, and anti-bot bypass
Reliable web access for AI agents: smart HTTP, rotating proxies, and full-browser rendering.
Isolated, fingerprint-protected browser profiles for AI agents: one per task, with its own proxy
Fetch web pages and APIs past anti-bot walls, with reusable browser sessions.
Related MCP Servers
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to perform undetectable browser automation that bypasses Cloudflare, antibots, and social media blocks. Provides 105 tools for element extraction, network debugging, and real-world web scraping with a 98.7% success rate on protected sites.187 PyPI3,387MIT
- AlicenseNot gradedqualityDmaintenanceProvides AI agents with reliable web fetching capabilities, handling retries, caching, and anti-bot bypass automatically.MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to perform stealth browser automation and anti-detection web interaction, including session management, humanized interactions, and bypassing anti-bot/WAF protections.MIT
- AlicenseBqualityBmaintenanceEnables AI agents to fetch web pages, convert them into token-efficient semantic Markdown, and extract hyperlinks and page metadata while rotating realistic browser fingerprints to reduce anti-bot blocks.3MIT