Skip to main content
Glama

scrape

Read-onlyIdempotent
Scrape a URL and return content in your preferred format.

Supported output formats:
- markdown (default): Clean LLM-ready Markdown text
- screenshot: PNG/JPEG image of the page
- pdf: PDF document of the page
- csv: Table data extracted as CSV
- html: Sanitized HTML with scripts/ads removed

This tool handles:
- JavaScript rendering (SPA, dynamic content)
- Anti-bot bypass (Cloudflare Turnstile, Datadome)
- DOM cleaning (strips scripts, nav, footer, ads)
- HTML-to-Markdown conversion (Mozilla Readability engine)
- Automatic retry with escalating wait strategies
- Domain cooldown to avoid rate-limiting
- Response caching (5 min TTL)

Args:
    url: The URL to scrape (must start with http:// or https://)
    output: Output format: "markdown" (default), "screenshot", "pdf", "csv", "html"
    wait_for_selector: Optional CSS selector to wait for before extraction (e.g., ".article-content")
    timeout_ms: Navigation timeout in milliseconds (default: 20000, max: 120000)
    block_media: Block images/fonts/video for faster loading (default: true)
    wait_strategy: Wait strategy: "default", "spa", "heavy", "cloudflare" (auto-detected if omitted)
    retry: Enable automatic retry on failure (default: true)
    bypass_cache: Skip cache, force fresh scrape (default: false)
    javascript: Custom JavaScript to execute after page load (e.g., "window.scrollTo(0, 1000)")

Returns:
    Content in the requested format, or an error message.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlYes
retryNo
outputNo
javascriptNo
timeout_msNo
block_mediaNo
bypass_cacheNo
wait_strategyNo
wait_for_selectorNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

TDQS

A4.8/5.0
Behavior5/5

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

The description goes far beyond the annotations by disclosing concrete behaviors: automatic retries with escalating waits, domain cooldown, 5-minute response caching, sanitization (strips scripts/ads), and the use of Mozilla Readability. It even explains what happens with bypass_cache and javascript execution. Nothing contradicts the readOnlyHint or idempotentHint annotations.

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?

The description is long but efficiently organized: a one-line purpose, a compact list of formats, a bulleted capability list, then an Args block with defaults. Every sentence adds operational value, and the most decision-relevant information (formats, key behaviors) is 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 tool with 9 parameters and no schema descriptions, the description includes everything needed to invoke it correctly: required URL format, all parameter defaults and semantics, output options, behavior on failure, caching, and a Returns section. The output schema presence and annotations further round out the picture, leaving no critical gaps.

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

Parameters5/5

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

Schema description coverage is 0%, so the description carries the entire burden of explaining all 9 parameters. The Args section describes every parameter with types, defaults, allowed values, and examples (e.g., wait_for_selector '.article-content', javascript 'window.scrollTo(0, 1000)'). This fully compensates for the empty schema descriptions.

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?

The description opens with a clear, specific verb-resource pair ('Scrape a URL and return content') and then enumerates supported output formats (markdown, screenshot, pdf, csv, html), which precisely scopes the tool. It is easily distinguishable from the sibling tools get_pricing and server_status, whose purposes are unrelated.

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

Usage Guidelines4/5

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

The description effectively communicates when to use this tool by detailing its capabilities (JavaScript rendering, anti-bot bypass, DOM cleaning, caching, etc.). It does not explicitly name alternatives or exclusion conditions, but the sibling tools are clearly different in purpose, making the appropriate context unambiguous.

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.

TDQS

A4.4/5.0
Disambiguation5/5

Each tool has a clearly distinct purpose: get_pricing handles payment info, scrape performs the core scraping, and server_status reports engine health. There is no overlap or ambiguity between them.

Naming Consistency4/5

get_pricing and scrape follow a simple verb-oriented pattern, but server_status deviates by using a noun_noun form instead of a verb-based name (e.g., get_status). The inconsistency is minor and does not hinder readability.

Tool Count5/5

Three tools is a well-scoped set for a BaaS scraping API: one to check pricing, one to scrape, and one to monitor server health. Each tool earns its place without unnecessary bloat.

Completeness4/5

Core scraping workflows are fully covered with flexible output formats and options. Minor gaps exist, such as no batch scraping or explicit API-key management, but these are not essential for the stated purpose and can be worked around.

Resources