# scrape402.xyz Basic Web Extraction

> scrape402.xyz Basic Web Extraction is a paid API for AI agents from scrape402.xyz, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-15).

Extracts content from any URL (as JSON or Markdown) via a pay-per-request micropayment model using x402/USDC on Base — no API key required.

## Facts

- Endpoint: POST https://scrape402.xyz/extract/basic
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/scrape402-xyz-basic-web-extraction-e316bde4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_QVbMbqBfs5lifmF3MRCUn

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 scrape402-xyz-basic-web-extraction-e316bde4 -d '<json body>'
```

Example prompt: Fetch the content of https://techcrunch.com/2026/01/15/some-article and give it to me as markdown, including all links and page metadata.

## When to prefer this

Choose this endpoint when you need to extract readable content from an arbitrary URL without managing API keys or subscriptions — especially in agentic pipelines where pay-per-use micropayments (USDC on Base via x402) are preferable to flat-rate credentials. Ideal for one-off or low-volume extractions where you want markdown or structured JSON output with metadata and links.

## Known failure modes

- No X-Payment header → 402 Payment Required with payment requirements details
- Invalid or unreachable URL → connection error or non-200 upstream response
- URL exceeds 2048 characters → validation error
- Unsupported format value → schema validation error
- Payment insufficient or invalid → payment rejection error
- Target site blocks scraping → empty or partial content returned

## How this service works

Extract clean text, links, and metadata from any URL as Markdown or JSON — single-page web scraping and structured data extraction for AI agents

## Output

A JSON object containing the page title, extracted content body (in JSON or Markdown format), an array of links (href + anchor text), metadata (word count, extraction method), latency in milliseconds, and the extraction timestamp.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "type": "string",
   "format": "uri",
   "maxLength": 2048,
   "description": "URL to extract"
  },
  "format": {
   "enum": [
    "json",
    "markdown"
   ],
   "type": "string",
   "default": "json"
  },
  "include_links": {
   "type": "boolean",
   "default": true
  },
  "include_metadata": {
   "type": "boolean",
   "default": true
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "url": "https://example.com/article",
  "links": [
   {
    "href": "https://example.com/other",
    "text": "Other"
   }
  ],
  "title": "Article Title",
  "format": "markdown",
  "content": "# Article\n\nBody text...",
  "metadata": {
   "word_count": 450,
   "extraction_method": "cheerio"
  },
  "latency_ms": 320,
  "extracted_at": "2026-01-01T00:00:00Z"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/scrape402-xyz-basic-web-extraction-e316bde4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from scrape402.xyz](https://www.zero.xyz/host/scrape402.xyz/llms.txt)
