# Web Scraper API – Link Extractor

> Web Scraper API – Link Extractor is a paid API for AI agents from web-scraper-api-production-bf20.up.railway.app, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-29).

Scrapes a webpage and returns all hyperlinks split into internal and external groups, each with anchor text and rel attribute, plus per-group counts.

## Facts

- Endpoint: POST https://web-scraper-api-production-bf20.up.railway.app/scrape/links?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-29
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/web-scraper-api-link-extractor-073e323d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_iR_ynYuJoZ2EYNhhSRE0z

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 web-scraper-api-link-extractor-073e323d -d '<json body>'
```

Example prompt: Pull all the internal and external links from https://www.example.com/blog — I want anchor text and rel attributes for each, plus a count of how many there are in each group.

## When to prefer this

Use this endpoint when you specifically need structured link data — internal vs. external classification, anchor text, and rel attributes — from a single page. Prefer it over full-page scrapers when your goal is link auditing, SEO analysis, or internal link mapping rather than body text or metadata extraction. It is more precise than a general scraper for link-focused tasks.

## Known failure modes

- Invalid or malformed URL returns a 400 error
- Page not publicly accessible (401/403) returns an access error
- Page takes too long to load causing a timeout
- URL resolves to a non-HTML resource (PDF, binary) may return empty or error
- Redirects to login walls return links from the login page, not the target content

## How this service works

Extract all links from a page split into internal and external, each with anchor text and rel attribute, plus per-group counts.

## Output

Returns a JSON object with two groups — internal links and external links — each containing an array of link objects (URL, anchor text, rel attribute) and a count for that group.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "type": "string",
   "description": "Absolute http(s) URL of the page to scrape, e.g. 'https://example.com'."
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/web-scraper-api-link-extractor-073e323d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from web-scraper-api-production-bf20.up.railway.app](https://www.zero.xyz/host/web-scraper-api-production-bf20.up.railway.app/llms.txt)
