Catalog/web-scrape

Web

Scrape by CSS selector API

Fetch a URL's HTML and extract elements by CSS selector into structured JSON (text, or a named attribute). Static HTML only (no JavaScript execution). Answers 'get the price from this page', 'extract all links', 'pull the h1 of this URL', 'scrape these fields from a page'.

Price$0.01per request
MethodPOST
Route/v1/web/scrape
StatusLive
MIME typeapplication/json
Rate limit30/minute
Cache600s public
webscrapecss-selectorextracthtmlparsecheeriostructured
API URLhttps://x402.hexl.dev/v1/web/scrape
Integration docs
Example request
{
  "url": "https://example.com",
  "selectors": [
    {
      "name": "title",
      "selector": "h1"
    },
    {
      "name": "links",
      "selector": "a",
      "attr": "href",
      "all": true
    }
  ]
}
Example response
{
  "url": "https://example.com",
  "extracted": {
    "title": "Example Domain",
    "links": [
      "https://www.iana.org/domains/example"
    ]
  }
}
Input schema
{
  "type": "object",
  "required": [
    "url",
    "selectors"
  ],
  "properties": {
    "url": {
      "type": "string",
      "examples": [
        "https://example.com"
      ]
    },
    "selectors": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "name",
          "selector"
        ],
        "properties": {
          "name": {
            "type": "string"
          },
          "selector": {
            "type": "string"
          },
          "attr": {
            "type": "string"
          },
          "all": {
            "type": "boolean"
          }
        }
      }
    }
  }
}
Output schema
{
  "type": "object",
  "additionalProperties": true
}