# Canonical URL Declaration HTML Fragment Extractor

> Canonical URL Declaration HTML Fragment Extractor is a paid API for AI agents from market.datapackvibe.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-11-18).

Extracts canonical URL declarations from HTML by parsing the <link rel='canonical'> tag from a supplied URL or raw HTML string

## Facts

- Endpoint: POST https://market.datapackvibe.com/x402/assistant-bx-web-canonical-html?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-18
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/canonical-url-declaration-html-fragment-extractor-3cd08e4e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_uuW8CXDZAXlLaCeDKF8Cb

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 canonical-url-declaration-html-fragment-extractor-3cd08e4e -d '<json body>'
```

Example prompt: Can you extract the canonical URL tag from this page — https://example.com/product-page — and give me back the full HTML fragment for the link element with id 'main-canonical'?

## When to prefer this

Choose this endpoint when you need to statically extract the canonical URL declaration (<link rel='canonical'>) from a single public page or known HTML string, especially in SEO auditing, content deduplication, or CMS validation workflows. It is well-suited for lightweight, low-cost ($0.01) per-page checks where JavaScript rendering is not needed and you know the target attribute to identify the element. Prefer alternatives if the page requires authentication, JavaScript rendering, or if you need to extract many different types of structured data beyond the canonical tag.

## Known failure modes

- URL is not publicly accessible or returns a non-200 status — extraction fails
- Canonical link element not present in HTML — returns empty or no result
- Attribute or attribute_value does not match any element — no fragment returned
- HTML exceeds 100,000 character limit — input rejected
- URL exceeds 2,048 character length — input rejected
- Page requires JavaScript rendering to expose canonical tag — static parser cannot find it
- Network timeout when fetching URL — extraction fails

## How this service works

Canonical URL declarations — HTML fragment extraction: HTML fragment extraction for Canonical URL declarations. One public HTTPS page or supplied HTML; static parsing, no JavaScript rendering, login or access bypass. Specialised preset in a shared 50-profile, 20-operation engine. 0.01 USDC includes one bounded html fragment extraction result.

## Output

Returns a bounded HTML fragment containing the extracted canonical URL declaration (the <link rel='canonical'> element) matching the specified attribute and attribute value, parsed statically from either a fetched public HTTPS page or supplied raw HTML — no JavaScript rendering or authentication required.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "type": "string",
   "default": "",
   "maxLength": 2048
  },
  "html": {
   "type": "string",
   "default": "<!doctype html><html><head></head><body><link rel=\"canonical\" href=\"https://www.iana.org/help/example-domains\" id=\"sample\"></body></html>",
   "maxLength": 100000
  },
  "term": {
   "type": "string",
   "default": "product",
   "maxLength": 100,
   "minLength": 1
  },
  "attribute": {
   "type": "string",
   "default": "id",
   "pattern": "^[a-zA-Z][a-zA-Z0-9:_-]{0,49}$",
   "maxLength": 50
  },
  "previous_texts": {
   "type": "array",
   "items": {
    "type": "string",
    "default": "",
    "maxLength": 1000
   },
   "default": [
    "Older example"
   ],
   "maxItems": 200,
   "minItems": 0
  },
  "attribute_value": {
   "type": "string",
   "default": "sample",
   "maxLength": 200
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/canonical-url-declaration-html-fragment-extractor-3cd08e4e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from market.datapackvibe.com](https://www.zero.xyz/host/market.datapackvibe.com/llms.txt)
