Skip to main content

x402-scraper

Lightweight httpx client for x402 Markdown Scraper. It wraps all five featured SKUs and settles x402 v2 Exact USDC on Base (eip155:8453). On HTTP 402 the x402 SDK builds the EIP-3009 transfer authorization, sets PAYMENT-SIGNATURE, and retries.

Install

pip install x402-scraper

Python 3.12 or 3.13 is recommended for EVM signing wheels.

Usage

import asyncio
import os

from x402_scraper import ScraperClient

os.environ["EVM_PRIVATE_KEY"] = "0x..."  # Base wallet that holds USDC


async def main() -> None:
    async with ScraperClient() as client:
        page = await client.scrape("https://example.com")       # $0.01
        brief = await client.summary("https://example.com")     # $0.02
        meta = await client.extract_metadata("https://example.com")  # $0.01
        pdf = await client.parse_pdf("https://example.com/paper.pdf")  # $0.05
        site = await client.deep_crawl("https://example.com", max_depth=2)  # $0.15
        print(page["sku"], brief["summary"], meta["word_count"], pdf["page_count"], site["page_count"])


asyncio.run(main())

Without EVM_PRIVATE_KEY, unpaid calls raise ScraperError with status_code=402 so you can inspect PAYMENT-REQUIRED yourself.

SKUs

Method Path Price
GET/POST /v1/scrape $0.01 USDC
GET/POST /v1/summary $0.02 USDC
GET/POST /v1/extract-metadata $0.01 USDC
GET/POST /v1/parse-pdf $0.05 USDC
GET/POST /v1/deep-crawl $0.15 USDC

Network: eip155:8453. Asset: Base USDC. Scheme: exact.

Shop docs: https://x402-markdown-scraper.onrender.com/docs

Metadata

Release files for x402-scraper 0.5.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for x402-scraper 0.5.1
File Size Uploaded Provenance Actions
x402_scraper-0.5.1.tar.gz 3.8 kB Without provenance Details for x402_scraper-0.5.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for x402-scraper 0.5.1
File Interpreter ABI Platform Actions
x402_scraper-0.5.1-py3-none-any.whl Python 3 none any Details for x402_scraper-0.5.1-py3-none-any.whl

Total release size: 7.7 kB

Release files / x402_scraper-0.5.1.tar.gz

Download URL x402_scraper-0.5.1.tar.gz
Size 3.8 kB
Tags Source
SHA-256 checksum
How to use checksums
8a7d5536b0c720312b5eb6e944b49ce610113dcf9abaa21cee9e661940f1de5e
BLAKE2b-256 checksum
How to use checksums
24e25104e3bcd9a4b53e632b5950d32bc6c31cf18c3cc45c37b9a1069409390c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.1

Release files / x402_scraper-0.5.1-py3-none-any.whl

Download URL x402_scraper-0.5.1-py3-none-any.whl
Size 4.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a152455f7bd1509dc25cc5894f4fe65a2a29b42fd300cbfe428bd436ca7ec9cb
BLAKE2b-256 checksum
How to use checksums
49955f1d05b05fad866b1b5c50a4fc1ef8fef31c447699568ea5885ebb478c95
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.1

Security for x402-scraper 0.5.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.5.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page