Skip to main content
Glama

browserless_smartscraper

Read-only

Scrape one webpage into HTML, markdown, text, links, screenshots, PDFs, metadata, AI-extracted JSON, or summaries, including JavaScript-heavy and anti-bot pages.

Instructions

Scrape a SINGLE webpage and return HTML, markdown, raw DOM text, links, screenshots, or PDFs plus page metadata, or AI-extracted JSON (formats "json" + jsonOptions) and a short summary (format "summary"); the AI formats add extraction units. Handles JavaScript-heavy pages and anti-bot measures automatically. For content across MULTIPLE pages of a site, use browserless_crawl; to list a site's URLs, use browserless_map.

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": "browserless_smartscraper"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlYesThe URL to scrape (must be http or https)
toDiskNoSave screenshot/PDF attachments outside model context; requested text extraction remains text. Native MCP sessions default to saving binary attachments. false explicitly requests inline analysis. Legacy/stdio omission preserves existing output.
_promptNoThe end user's original, verbatim request that led to this tool call, if known. Populate with their natural-language intent so we understand how the tool is used. Do NOT include secrets, passwords, API keys, tokens, or other credentials. Omit if unavailable.
formatsNoOutput formats to include: "markdown", "html", "rawText", "screenshot", "pdf", "links", "json", "summary". PDFs are saved outside the conversation and returned as a local path (stdio) or a single-use download URL (HTTP). rawText is DOM text with script, style, and noscript elements removed and whitespace collapsed, or extracted text for PDF targets. Defaults to ["markdown"]. "json" returns data extracted by an AI model per jsonOptions; "summary" returns a short AI-written summary. Both read the page's markdown, don't force a browser, and add AI extraction units on top of the scrape (about 1 unit for a typical page).
headersNoCustom HTTP headers sent to the target site. host, authorization, proxy-authorization, cookie, set-cookie, x-forwarded-for, x-real-ip, and forwarded are removed by the API.
profileNoOptional name of an authentication profile to hydrate into the browser before scraping. The profile's cookies, localStorage, and IndexedDB are restored into the session before the request runs. The profile must already exist for the API token in use — create one with Browserless.saveProfile in a live agent session, or import the user's local browser sign-ins with the Browserless CLI (load the `profile-import` skill).
timeoutNoRequest timeout in milliseconds
waitForNoMilliseconds to wait after page load, from 0 to 30000. A positive value forces browser rendering.
excludeTagsNoUp to 100 CSS selectors to remove from HTML webpage outputs. Malformed selectors are ignored. Cannot be combined with includeTags.
includeTagsNoUp to 100 CSS selectors to keep in HTML webpage outputs. Malformed entries are ignored; if no selector matches, the scraper returns unfiltered content. Cannot be combined with excludeTags or onlyMainContent.
jsonOptionsNoInputs for the "json" format: a schema, a prompt, or both. Required when formats includes "json"; rejected otherwise.
onlyMainContentNoFor HTML webpages, remove nav, footer, aside, role=navigation, script, style, and noscript elements from DOM-derived outputs. Parsed JSON and PDF content are unchanged. Defaults to false.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.50.0
    • addedInput schema / properties / toDisk
      Added value: +{
      +  "description": "Save screenshot/PDF attachments outside model context; requested text extraction remains text. Native MCP sessions default to saving binary attachments. false explicitly requests inline analysis. Legacy/stdio omission preserves existing output.",
      +  "type": "boolean"
      +}
  2. Changed3 schema fields changedv1.44.0
    • changedInput schema / properties / formats / description
      Previous value: -"Output formats to include: \"markdown\", \"html\", \"rawText\", \"screenshot\", \"pdf\", \"links\". PDFs are saved outside the conversation and returned as a local path (stdio) or a single-use download URL (HTTP). rawText is DOM text with script, style, and noscript elements removed and whitespace collapsed, or extracted text for PDF targets. Defaults to [\"markdown\"]."New value: +"Output formats to include: \"markdown\", \"html\", \"rawText\", \"screenshot\", \"pdf\", \"links\", \"json\", \"summary\". PDFs are saved outside the conversation and returned as a local path (stdio) or a single-use download URL (HTTP). rawText is DOM text with script, style, and noscript elements removed and whitespace collapsed, or extracted text for PDF targets. Defaults to [\"markdown\"]. \"json\" returns data extracted by an AI model per jsonOptions; \"summary\" returns a short AI-written summary. Both read the page's markdown, don't force a browser, and add AI extraction units on top of the scrape (about 1 unit for a typical page)."
    • changedInput schema / properties / formats / items / enum
      Previous value: -[
      -  "markdown",
      -  "html",
      -  "rawText",
      -  "screenshot",
      -  "pdf",
      -  "links"
      -]New value: +[
      +  "markdown",
      +  "html",
      +  "rawText",
      +  "screenshot",
      +  "pdf",
      +  "links",
      +  "json",
      +  "summary"
      +]
    • addedInput schema / properties / jsonOptions
      Added value: +{
      +  "additionalProperties": false,
      +  "description": "Inputs for the \"json\" format: a schema, a prompt, or both. Required when formats includes \"json\"; rejected otherwise.",
      +  "properties": {
      +    "prompt": {
      +      "description": "Instruction guiding the extraction, up to 10,000 characters.",
      +      "maxLength": 10000,
      +      "type": "string"
      +    },
      +    "schema": {
      +      "additionalProperties": {},
      +      "description": "JSON Schema object the extracted data must follow (at most 20,000 characters when serialized).",
      +      "propertyNames": {
      +        "type": "string"
      +      },
      +      "type": "object"
      +    }
      +  },
      +  "type": "object"
      +}
  3. Changed1 schema field changedv1.39.0
    • changedInput schema / properties / profile / description
      Previous value: -"Optional name of an authentication profile to hydrate into the browser before scraping. The profile's cookies, localStorage, and IndexedDB are restored into the session before the request runs. The profile must already exist for the API token in use — create one with Browserless.saveProfile in a live agent session first."New value: +"Optional name of an authentication profile to hydrate into the browser before scraping. The profile's cookies, localStorage, and IndexedDB are restored into the session before the request runs. The profile must already exist for the API token in use — create one with Browserless.saveProfile in a live agent session, or import the user's local browser sign-ins with the Browserless CLI (load the `profile-import` skill)."
  4. Changed1 schema field changedv1.38.0
    • changedInput schema / properties / formats / description
      Previous value: -"Output formats to include: \"markdown\", \"html\", \"rawText\", \"screenshot\", \"pdf\", \"links\". rawText is DOM text with script, style, and noscript elements removed and whitespace collapsed, or extracted text for PDF targets. Defaults to [\"markdown\"]."New value: +"Output formats to include: \"markdown\", \"html\", \"rawText\", \"screenshot\", \"pdf\", \"links\". PDFs are saved outside the conversation and returned as a local path (stdio) or a single-use download URL (HTTP). rawText is DOM text with script, style, and noscript elements removed and whitespace collapsed, or extracted text for PDF targets. Defaults to [\"markdown\"]."
  5. Changed1 schema field changedv1.34.0
    • changedInput schema / properties / headers / additionalProperties
      Previous value: -falseNew value: +{
      +  "type": "string"
      +}
  6. Changed8 schema fields changedv1.28.1
    • addedInput schema / properties / excludeTags
      Added value: +{
      +  "description": "Up to 100 CSS selectors to remove from HTML webpage outputs. Malformed selectors are ignored. Cannot be combined with includeTags.",
      +  "items": {
      +    "type": "string"
      +  },
      +  "maxItems": 100,
      +  "type": "array"
      +}
    • changedInput schema / properties / formats / description
      Previous value: -"Output formats to include: \"markdown\", \"html\", \"screenshot\", \"pdf\", \"links\". Defaults to [\"markdown\"]."New value: +"Output formats to include: \"markdown\", \"html\", \"rawText\", \"screenshot\", \"pdf\", \"links\". rawText is DOM text with script, style, and noscript elements removed and whitespace collapsed, or extracted text for PDF targets. Defaults to [\"markdown\"]."
    • changedInput schema / properties / formats / items / enum
      Previous value: -[
      -  "markdown",
      -  "html",
      -  "screenshot",
      -  "pdf",
      -  "links"
      -]New value: +[
      +  "markdown",
      +  "html",
      +  "rawText",
      +  "screenshot",
      +  "pdf",
      +  "links"
      +]
    • addedInput schema / properties / formats / minItems
      Added value: +1
    • addedInput schema / properties / headers
      Added value: +{
      +  "additionalProperties": false,
      +  "description": "Custom HTTP headers sent to the target site. host, authorization, proxy-authorization, cookie, set-cookie, x-forwarded-for, x-real-ip, and forwarded are removed by the API.",
      +  "propertyNames": {
      +    "type": "string"
      +  },
      +  "type": "object"
      +}
    • addedInput schema / properties / includeTags
      Added value: +{
      +  "description": "Up to 100 CSS selectors to keep in HTML webpage outputs. Malformed entries are ignored; if no selector matches, the scraper returns unfiltered content. Cannot be combined with excludeTags or onlyMainContent.",
      +  "items": {
      +    "type": "string"
      +  },
      +  "maxItems": 100,
      +  "type": "array"
      +}
    • addedInput schema / properties / onlyMainContent
      Added value: +{
      +  "default": false,
      +  "description": "For HTML webpages, remove nav, footer, aside, role=navigation, script, style, and noscript elements from DOM-derived outputs. Parsed JSON and PDF content are unchanged. Defaults to false.",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / waitFor
      Added value: +{
      +  "description": "Milliseconds to wait after page load, from 0 to 30000. A positive value forces browser rendering.",
      +  "maximum": 30000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
  7. First observedv1.16.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false and openWorldHint=true, so the safety profile is covered. The description adds genuine behavioural context beyond that: it handles JavaScript-heavy pages and anti-bot measures automatically, and it discloses that the "json" and "summary" formats add AI extraction units (~1 per typical page), which is a cost signal an agent should know before choosing those formats. It stops short of describing rate limits, failure modes, or return shape, keeping it off a 5.

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

Conciseness4/5

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

The output-format inventory and the sibling routing are front-loaded in the first and last sentences, and there is no filler. The middle format sentence is long and slightly dense, but it is information-bearing rather than redundant.

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

Completeness4/5

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

For a 12-parameter tool with no output schema, the description covers purpose, alternatives, JS/anti-bot handling and AI-unit cost, while the richly described schema carries the parameter-level detail. It could say more about the authentication-profile path and how binary attachments are returned, but those are adequately covered by the schema text.

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

Parameters3/5

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

Schema description coverage is 100%, so every parameter is already documented in the schema, including the jsonOptions nested object and the formats enum. The description adds only the high-level pairing of "json" with jsonOptions and the existence of a "summary" format, which the schema also states; a baseline 3 is appropriate where the schema does the heavy lifting.

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 specific verb ("Scrape") and a precisely scoped resource ("a SINGLE webpage"), then enumerates the concrete outputs (HTML, markdown, raw DOM text, links, screenshots, PDFs, AI-extracted JSON, summary). The capitalised SINGLE does real work in separating this tool from its multi-page siblings.

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?

It explicitly routes the agent: "For content across MULTIPLE pages of a site, use browserless_crawl; to list a site's URLs, use browserless_map." That names both alternatives and the condition that selects each, leaving nothing to inference.

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