8000 GitHub - dominion525/gangue: Fetch a web page's main content and convert it to clean Markdown — an MCP server and CLI. · GitHub
[go: up one dir, main page]

Skip to content
dominion525Public

About

Fetch a web page's main content and convert it to clean Markdown — an MCP server and CLI.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

gangue

Fetch a web page's main content and convert it to clean Markdown — as an MCP server and a CLI.

日本語版: README.ja.md

gangue renders a URL with headless Chrome, strips navigation, ads, and other noise, extracts the main article, and returns clean Markdown. It exposes a single MCP tool, fetch_markdown, and also works as a one-shot CLI.

Features

  • One tool, one job: fetch_markdown(url) -> Markdown. Nothing else.
  • Real rendering: uses headless Chrome, so JavaScript-rendered pages work.
  • Clean output: readability-style main-content extraction, converted to Markdown. If extraction finds too little, gangue falls back to the whole page, so you still get the content.
  • MCP server or CLI: run it as a stdio MCP server, or pass a URL to print Markdown to stdout.
  • Self-healing browser: the browser is launched once and reused; if it dies, gangue restarts it and retries.

Requirements

  • Google Chrome or Chromium installed on the system (gangue does not bundle a browser).
  • For the npx install method: Node.js.

Install

As an MCP server (recommended)

Register gangue with your MCP client. With Claude Code:

claude mcp add --transport stdio gangue -- npx -y gangue@latest

Or in .mcp.json:

{
  "mcpServers": {
    "gangue": {
      "command": "npx",
      "args": ["-y", "gangue@latest"]
    }
  }
}

@latest makes npx fetch the newest published version on each launch, so you stay up to date.

From source

cargo install --git https://github.com/dominion525/gangue

Usage

MCP tool

Once registered, the fetch_markdown tool is available:

  • fetch_markdown(url: string) -> string — returns the page's main content as Markdown.

CLI

gangue https://example.com/

Prints the Markdown to stdout. With no argument, gangue runs as an MCP stdio server.

How it works

URL
  → headless Chrome renders the page
  → readability extracts the main content (relative links resolved to absolute)
  → HTML is converted to Markdown, with the title as a leading heading
  → Markdown

License

Licensed under either of MIT or Apache-2.0 at your option.

About

Fetch a web page's main content and convert it to clean Markdown — an MCP server and CLI.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

0