Skip to main content
Glama

Extract structured data from a page

extract_data
Read-only

Fetch a URL and return JSON built from CSS or XPath selectors, so the model receives structured fields instead of a whole page.

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>",
      "extract_rules": "<extract_rules>"
    },
    "name": "extract_data"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlYesThe absolute http or https URL to fetch.
render_jsNoRender in a browser before extracting.
extract_rulesYesMap a name to a selector. A string is shorthand for the text of the first match, and "a@href" takes an attribute. An object may set selector, selector_type (auto, css, xpath), type (item or list), and output (text, html, @attr, table_json, table_array, or a nested object of further rules). Example: {"titles": {"selector": "h2", "type": "list"}}

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

Score is being calculated.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.