mcp npx fetch
A powerful MCP server for fetching and transforming web content into various formats (HTML, JSON, Markdown, Plain Text) with ease.
A powerful MCP server for fetching and transforming web content into various formats (HTML, JSON, Markdown, Plain Text) with ease.
npm install -g @tokenizin/mcp-npx-fetch
npx @tokenizin/mcp-npx-fetch
fetch_html
Fetches and returns raw HTML content from any URL.
{
url: string; // Required: Target URL
headers?: { // Optional: Custom request headers
[key: string]: string;
};
}
fetch_json
Fetches and parses JSON data from any URL.
{
url: string; // Required: Target URL
headers?: { // Optional: Custom request headers
[key: string]: string;
};
}
fetch_txt
Fetches and returns clean plain text content, removing HTML tags and scripts.
{
url: string; // Required: Target URL
headers?: { // Optional: Custom request headers
[key: string]: string;
};
}
fetch_markdown
Fetches content and converts it to well-formatted Markdown.
{
url: string; // Required: Target URL
headers?: { // Optional: Custom request headers
[key: string]: string;
};
}
Start the MCP server directly:
mcp-npx-fetch
Or via npx:
npx @tokenizin/mcp-npx-fetch
Locate your Claude Desktop configuration file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%/Claude/claude_desktop_config.json
Linux: ~/.config/Claude/claude_desktop_config.json
Add the following configuration to your mcpServers
object:
{
"mcpServers": {
"fetch": {
"command": "npx",
"args": ["-y", "@tokenizin/mcp-npx-fetch"],
"env": {}
}
}
}
git clone https://github.com/tokenizin-agency/mcp-npx-fetch.git
cd mcp-npx-fetch
npm install
npm run dev
npm test
Contributions are welcome! Please feel free to submit a Pull Request. For major changes, please open an issue first to discuss what you would like to change.
git checkout -b feature/AmazingFeature
)git commit -m 'Add some AmazingFeature'
)git push origin feature/AmazingFeature
)This project is licensed under the MIT License - see the LICENSE file for details.
[
{
"description": "Fetch a website and return the content as HTML",
"inputSchema": {
"properties": {
"headers": {
"description": "Optional headers to include in the request",
"type": "object"
},
"url": {
"description": "URL of the website to fetch",
"type": "string"
}
},
"required": [
"url"
],
"type": "object"
},
"name": "fetch_html"
},
{
"description": "Fetch a website and return the content as Markdown",
"inputSchema": {
"properties": {
"headers": {
"description": "Optional headers to include in the request",
"type": "object"
},
"url": {
"description": "URL of the website to fetch",
"type": "string"
}
},
"required": [
"url"
],
"type": "object"
},
"name": "fetch_markdown"
},
{
"description": "Fetch a website, return the content as plain text (no HTML)",
"inputSchema": {
"properties": {
"headers": {
"description": "Optional headers to include in the request",
"type": "object"
},
"url": {
"description": "URL of the website to fetch",
"type": "string"
}
},
"required": [
"url"
],
"type": "object"
},
"name": "fetch_txt"
},
{
"description": "Fetch a JSON file from a URL",
"inputSchema": {
"properties": {
"headers": {
"description": "Optional headers to include in the request",
"type": "object"
},
"url": {
"description": "URL of the JSON to fetch",
"type": "string"
}
},
"required": [
"url"
],
"type": "object"
},
"name": "fetch_json"
}
]