Skip to main content
Glama

mcp-reader

MCP server for @vakra-dev/reader: scrape and crawl websites using a real browser, and keep LLM context small with artifact offloading.

This server is built for Claude Code / OpenCode:

  • Tool outputs are intentionally compact (summaries + artifact ids).

  • Full payloads (manifests, markdown, html, url lists) are stored as artifacts.

  • Agents fetch only what they need via reader_artifact_get (grep, range, head, tail).

Requirements

  • Node: >=24

  • @vakra-dev/reader is an optional dependency. If it fails to install (native deps), mcp-reader will still install, but scrape/crawl tools will fail until Reader is installed.

Recommended:

  • Use Node 24.x for the smoothest native-dependency story.

Related MCP server: snoopscan

Install

npm install mcp-reader

If Reader did not install automatically (you will see warnings during npm install), install it explicitly:

npm install @vakra-dev/reader

Configure (Claude Code / OpenCode)

Recommended (Windows-safe): run through node to avoid .cmd wrapper spawning issues.

{
  "mcpServers": {
    "reader": {
      "command": "node",
      "args": ["./node_modules/mcp-reader/dist/cli.js"],
      "env": {
        "MCP_READER_LOG_LEVEL": "info",
        "MCP_READER_STORE": "file:.mcp-reader-artifacts",
        "MCP_READER_MAX_BYTES": "80000",
        "MCP_READER_PREVIEW_MAX_CHARS": "6000"
      }
    }
  }
}

Tools

  • reader_scrape: Scrape 1+ URLs. Returns a summary and stores a scrape manifest + per-page markdown/html as artifacts.

  • reader_crawl: Crawl a site (depth/maxPages/pattern filters) and optionally scrape discovered pages. Stores crawl manifest + URL list (+ scrape manifest if enabled).

  • reader_challenge: Detect Cloudflare/anti-bot challenge and optionally wait for resolution.

  • reader_status: Show server config + whether ReaderClient is initialized.

  • reader_warmup: Warm up ReaderClient/browser core.

  • reader_close: Close ReaderClient/browser pools.

Artifacts (token saving):

  • reader_artifact_get: Fetch slices of stored artifacts (auto|head|tail|range|grep|full|json).

  • reader_artifact_info: Artifact metadata.

  • reader_artifact_list: List recent artifacts.

  • reader_artifact_delete: Delete an artifact.

How To Use (Humans)

Read a single page (main content -> markdown):

{
  "url": "https://docs.reader.dev/documentation/overview",
  "formats": ["markdown"],
  "onlyMainContent": true
}

You will receive:

  • a compact scrape summary

  • a manifest artifact id with per-page markdownArtifactId / htmlArtifactId

Then fetch the markdown artifact:

{ "id": "art_...", "mode": "head", "headLines": 80 }

How To Use (Agents)

Start with the smallest signal:

  1. reader_crawl with preview: "summary" to get a URL inventory.

  2. Use reader_artifact_get with grep / range on the URL list artifact.

  3. reader_scrape only the handful of relevant URLs.

  4. Fetch only the needed slices of markdown via reader_artifact_get.

More: AGENTS.md

Artifact Storage + Truncation

Artifact store:

  • MCP_READER_STORE: memory (default) or file:.mcp-reader-artifacts

Truncation knobs:

  • MCP_READER_MAX_BYTES: Offload threshold (default 80000)

  • MCP_READER_PREVIEW_MAX_CHARS: Preview cap (default 6000)

  • MCP_READER_HEAD_LINES / MCP_READER_TAIL_LINES: Preview slices (default 60 / 60)

  • MCP_READER_TTL_SECONDS: Optional TTL for memory store

  • MCP_READER_MAX_ARTIFACTS: Optional cap for memory store

ReaderClient Configuration

Configure Reader via env (JSON):

  • MCP_READER_BROWSER_POOL: { "size": 2, "retireAfterPages": 100, "retireAfterMinutes": 30, "maxQueueSize": 100 }

  • MCP_READER_PROXIES: [ { "url": "http://user:pass@host:port", "country": "US" } ]

  • MCP_READER_PROXY_ROTATION: round-robin or random

  • MCP_READER_VERBOSE: true|false

  • MCP_READER_SHOW_CHROME: true|false

Documentation

  • docs/TOOLS.md: tool-by-tool reference with examples

  • docs/CONFIG.md: configuration and environment variables

  • docs/TRUNCATION.md: artifact modes and token-saving patterns

  • docs/RELEASE.md: CI/CD + release + npm publish

CI / Releases / npm publish

  • CI: lint + typecheck + tests + build

  • Releases: Release Please opens a PR with version bump + changelog

  • Publish: on release creation, GitHub Actions publishes to npm

Required GitHub secrets:

  • NPM_TOKEN: npm automation token with publish rights

Development

npm run lint
npm run typecheck
npm test
npm run build

License

GPL-3.0-only. See LICENSE.

Available Tools

10 tools
reader_artifact_deleteC

Delete a stored artifact by id.

Inputs: id (required).

reader_artifact_getC

Fetch a slice of an offloaded artifact (auto/head/tail/range/grep/full/json).

Inputs: id (required), mode, endLine, pattern, +5 more.

reader_artifact_infoC

Get metadata about a stored artifact.

Inputs: id (required).

reader_artifact_listC

List stored artifacts (most recent first).

Inputs: limit.

reader_challengeC

Detect Cloudflare/anti-bot challenges using Reader's BrowserPool utilities; optionally wait for resolution.

Inputs: url (required), verbose, maxWaitMs, pollIntervalMs, +1 more.

reader_closeA

Close the internal ReaderClient and any browser pools.

Inputs: no named parameters.

reader_crawlC

Crawl a website (depth/maxPages/patterns) and optionally scrape discovered pages. Returns a compact summary and stores a crawl manifest + URL list (and scrape manifest if enabled) as artifacts.

Inputs: url (required), depth, proxy, scrape, +11 more.

reader_scrapeC

Scrape one or more URLs with @vakra-dev/reader. Returns a compact summary and stores a manifest + per-page markdown/html as artifacts.

Inputs: url, urls, proxy, formats, +15 more.

reader_statusA

Show MCP Reader server status and configuration.

Inputs: no named parameters.

reader_warmupA

Warm up the internal ReaderClient (start browser core) to reduce first-call latency.

Inputs: no named parameters.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 10 tools

    Disambiguation4/5

    Each tool has a clearly distinct purpose: scraping, crawling, challenge detection, lifecycle management, status, and artifact operations. The only minor potential overlap is between reader_challenge and reader_scrape (since scraping may encounter challenges), but the descriptions clarify that challenge detection is a separate diagnostic operation.

    Naming Consistency4/5

    All tools share the reader_ prefix and use consistent snake_case. The artifact operations follow a clean reader_artifact_* subgroup, though a few names (e.g., reader_status, reader_close) are noun/verb rather than the dominant verb_noun pattern—still highly readable and predictable.

    Tool Count5/5

    Ten tools is well-scoped for a web-reading/scraping server. Every tool earns its place: core scraping/crawling, lifecycle helpers, status, and a focused artifact management subgroup. No obvious bloat or missing essentials.

    Completeness4/5

    The surface covers scraping, crawling, challenge detection, lifecycle management, and artifact read/list/info/delete operations. A minor gap is the lack of an explicit artifact-update or export operation, but core workflows are fully supported without dead ends.

    Maintenance

    ActivityNo data
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables coding agents to retrieve verified web evidence via headless Chromium rendering, sitemap navigation, and search candidate discovery, returning clean Markdown, structured JSON, and verbatim quoted proof.
      6 npm
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables agents to scrape, crawl, map, search, and extract web pages as clean markdown or structured JSON directly through MCP tools.
      AGPL 3.0
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables AI agents to read web pages as clean markdown or JSON, crawl sites, search the web with results already read, monitor pages for changes, and run multi-step browser tasks under configurable limits.
      MIT
    • F
      license
      B
      quality
      B
      maintenance
      Enables coding agents and scripts to crawl and map sites, read pages as clean Markdown or structured content, extract data with schemas or local AI, and run multi-angle deep research with numbered sources. It also handles JavaScript-rendered pages through a headless browser and applies safety controls for private addresses, robots.txt, and polite pacing.
      10
      -