AARN.
x402 structured extraction · Base / USDC

Webpage to JSON API — Web Extract JSON

Convert readable content from one public HTML page into a strict JSON object. Specify up to six flat nullable fields, such as a product name and price; missing or ambiguous values become null.

Catalog price · one public URL

0.015 USDC / request

The live HTTP 402 payment challenge is authoritative for availability, Base USDC asset, recipient and exact amount. It is not proof of successful paid delivery.

Method: POST · Canonical endpoint: https://api.aarn.space/v1/web/extract-json

What you get

  • One public HTML/XHTML URL per request; no login or JavaScript rendering
  • One strict, flat JSON object matching the supplied schema
  • Up to six required fields, each a nullable string, number, integer or boolean
  • Unavailable or ambiguous values are null; non-null values must be supported by source text

Developer workflow

For a public product information page, define nullable name and price fields as shown below. Validate the returned JSON against your schema, retain the input URL, and treat null as missing or ambiguous rather than zero. Verify important values against the source before using them in automated decisions.

If you need the full readable source instead of selected fields, use the URL-to-Markdown API or multi-URL extraction API.

Using ChatGPT or an MCP client? Explore AARN's free MCP discovery preview to inspect the tool contract; discovery does not retrieve content, execute paid services or fund a buyer.

Request example

Documentation only. This JSON contains the exact public request keys; viewing it does not initiate a call or a payment.

{
  "url": "https://example.com/product",
  "schema": {
    "type": "object",
    "properties": {
      "name": {"type": ["string", "null"]},
      "price": {"type": ["number", "null"]}
    },
    "required": ["name", "price"],
    "additionalProperties": false
  }
}

All properties must appear in required, in the same order. additionalProperties must be false. Nested objects, arrays, references and arbitrary regular expressions are unsupported. Consult OpenAPI for the canonical contract.

Inspect without paying

An unsigned request returns HTTP 402 with an encoded PAYMENT-REQUIRED header when the offering is ready; otherwise it may return HTTP 503. Neither response charges a wallet or invokes paid model inference.

For an x402-compatible buyer, download the Python or Node.js example. Their default mode performs an unpaid preview:

python aarn_x402_python.py web_extract_json:v1
# OR
node aarn_x402_node.mjs web_extract_json:v1

Do not add --pay just to test this offering. That option makes a real buyer-funded purchase and is only for independently authorized clients with their own wallet, after verifying the live challenge and spend limit. Never retry an uncertain paid response before settlement reconciliation.

Boundaries and quality

AARN extracts only the first 3,500 characters of prepared page content for JSON inference and does not promise comprehensive coverage of long documents. PDFs, authenticated or private pages, JavaScript-rendered content and unconstrained schemas are unsupported. LLM extraction and QA cannot guarantee semantic truth; verify critical values independently.

Successful paid execution requires provider availability, customer-funded settlement before paid inference, internal revenue/budget/risk authorization and QA. A listing or x402 402 does not prove a paid transaction completed. See the live manifest and buyer integration guide for current availability.

← Back to all services