# FastX402 HTML Extract Links

> FastX402 HTML Extract Links is a paid API for AI agents from fastx402.tools, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-27).

Parses an HTML document or fragment and extracts all hyperlinks with their href, text, and attributes

## Facts

- Endpoint: GET https://fastx402.tools/html-extract-links?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-27
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/fastx402-html-extract-links-a35fa264
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_euOy4ZRWU9T0hSrHUuEDn

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability fastx402-html-extract-links-a35fa264
```

Example prompt: Here's the raw HTML from a webpage — can you extract all the hyperlinks from it, including the link text and href for each one? <paste HTML here>

## When to prefer this

Choose this endpoint when you already have raw HTML content in hand and need a quick, structured extraction of all anchor links without setting up a browser, DOM parser, or full scraping pipeline. It is ideal for lightweight link harvesting within an agentic workflow where you want to avoid heavy dependencies and pay only $0.002 per call with no account or API key required.

## Known failure modes

- Missing or empty html query parameter returns an error
- Malformed or non-HTML input may yield zero links or parsing errors
- Very large HTML documents may hit request size limits
- Relative hrefs are returned as-is without resolution to absolute URLs
- Payment failure via x402 protocol returns 402 before processing

## How this service works

216 pay-per-call tools for AI agents, from $0.001 per request in USDC on Base or Solana with x402. No account, no API key.

## Output

A JSON object containing a count of links found and an array of link objects, each with an href (URL or relative path), text (the visible anchor text), and an attributes object containing any additional HTML attributes on the anchor element.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "html"
     ],
     "properties": {
      "html": {
       "type": "string",
       "description": "HTML document or fragment to parse"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "count": {
       "type": "integer"
      },
      "links": {
       "type": "array",
       "items": {
        "type": "object",
        "properties": {
         "href": {
          "type": "string"
         },
         "text": {
          "type": "string"
         },
         "attributes": {
          "type": "object",
          "properties": {}
         }
        }
       }
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "count": 2,
  "links": [
   {
    "href": "https://example.com",
    "text": "Example",
    "attributes": {}
   },
   {
    "href": "/about",
    "text": "About",
    "attributes": {
     "class": "nav"
    }
   }
  ]
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/fastx402-html-extract-links-a35fa264/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from fastx402.tools](https://www.zero.xyz/host/fastx402.tools/llms.txt)
