Skip to main content
Glama

extract_content

Read-only

Read a public web page as clean markdown (or text, html, article, links, metadata), fully rendered first. Use it after take_screenshot when you need the words, or on its own for research. Uses one capture; failed extractions are free. Returns up to max_length characters (default: 100,000); pass selector, for example main or article, to keep it short. Public URLs only.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "url": "<url>"
    },
    "name": "extract_content"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlYesURL to extract content from (must start with http:// or https://)
typeNoWhat to return: markdown (default, readable content), text (plain text), html (raw HTML), article (title, author, excerpt and content), links (every link on the page), metadata (title, description, Open Graph and Twitter tags)
delayNoExtra milliseconds to wait after the page loads, 0-10000 (default: 0)
selectorNoCSS selector to read only part of the page, for example main or article
block_adsNoBlock ads and trackers (default: true)
max_lengthNoMaximum characters to return, 1-500000 (default: 100000)
block_cookie_bannersNoRemove cookie consent banners (default: true)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • changedInput schema / properties / block_ads / description
      Previous value: -"Block advertisements and trackers (default: true)"New value: +"Block ads and trackers (default: true)"
    • changedInput schema / properties / delay / description
      Previous value: -"Milliseconds to wait after page load (default: 0)"New value: +"Extra milliseconds to wait after the page loads, 0-10000 (default: 0)"
    • changedInput schema / properties / max_length / description
      Previous value: -"Maximum content length in characters (default: 100000)"New value: +"Maximum characters to return, 1-500000 (default: 100000)"
    • changedInput schema / properties / selector / description
      Previous value: -"CSS selector to scope extraction to a specific element"New value: +"CSS selector to read only part of the page, for example main or article"
    • changedInput schema / properties / type / description
      Previous value: -"Extraction type (default: markdown)"New value: +"What to return: markdown (default, readable content), text (plain text), html (raw HTML), article (title, author, excerpt and content), links (every link on the page), metadata (title, description, Open Graph and Twitter tags)"
  2. Added

TDQS

A4.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly/openWorld/non-destructive, and the description adds material context beyond them: pages are fully rendered first, only one capture is consumed, and failed extractions are free (a cost/billing trait). The public-URL-only limit is also disclosed. It stops short of explaining truncation behavior when max_length is hit, but the added value is substantial.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four tight sentences: capability first, then sibling guidance, then cost/limit facts. No filler, no restating the title, and the most decision-relevant facts are front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 7-parameter extraction tool with no output schema, it covers return formats, default size limits, rendering behavior, cost implications, and access restrictions. Nothing an agent needs to invoke it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so 3 is the baseline, but the description adds practical intent: max_length defaults to 100,000 characters and selector exists to keep responses short (with 'main' or 'article' as examples). That explains why to use selector, not just what it accepts.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource ('Read a public web page') and enumerates the exact output representations (markdown, text, html, article, links, metadata). This clearly separates it from the visual-capture siblings like take_screenshot.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit sequencing guidance ('after take_screenshot when you need the words') plus a standalone use case ('on its own for research'), and an exclusion ('Public URLs only'). An agent can decide between this and the screenshot tools without inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.