WritersLogic Verifiable AI Agent Hub Heal Scraper API
The Heal Scraper API from WritersLogic Verifiable AI Agent Hub — 1 operation(s) for heal scraper.
The Heal Scraper API from WritersLogic Verifiable AI Agent Hub — 1 operation(s) for heal scraper.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/writerslogic-com:writerslogic-com-heal-scraper-api"
curl "https://apis.io/api/v1/apis?limit=25"
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: WritersLogic Verifiable AI Agent Hub Heal Scraper API
version: 2.0.0
description: Pay-per-call agents settled in USDC on Base via x402. Every response carries a signed provenance envelope.
contact:
name: WritersLogic
url: https://writerslogic.com/agents
email: agents@writerslogic.com
servers:
- url: https://agents.writerslogic.com
tags:
- name: Heal Scraper
paths:
/api/v1/heal-scraper:
post:
operationId: heal_scraper
summary: Self-Healing Scraper & DOM-to-JSON Compiler
description: 'Synthesizes durable CSS selectors (Cheerio; no XPath) for a target JSON schema, proves them against the live DOM in-request, and returns the extracted data plus a ready-to-run TypeScript Cheerio extractor.
Price: 0.40 USDC on Base (x402).'
x-x402-price-usdc: '0.40'
x-x402-amount: '400000'
x-payment-info:
protocols:
- x402
price:
mode: fixed
currency: USD
amount: '0.40'
x-audience: developer
x-sample-url: https://agents.writerslogic.com/api/v1/samples/heal-scraper
security:
- x402: []
- apiKey: []
requestBody:
required: true
content:
application/json:
schema:
type: object
additionalProperties: false
required:
- targetSchema
properties:
url:
type: string
maxLength: 2048
description: Page to fetch. Provide url or html.
html:
type: string
maxLength: 1500000
description: Raw HTML to use instead of fetching.
targetSchema:
type: object
description: 'JSON Schema of the fields to extract: an object whose properties are string/number/integer/boolean (or arrays of those), or an array whose items are such an object for list pages. The pattern keyword is not allowed.'
previousBrokenSelectors:
type: object
description: Map of field name to the CSS selector that stopped working.
example:
url: https://news.ycombinator.com
targetSchema:
type: array
items:
type: object
required:
- title
- link
properties:
title:
type: string
link:
type: string
points:
type: integer
previousBrokenSelectors:
title: .storylink
responses:
'200':
description: Paid result with provenance
content:
application/json:
schema:
type: object
properties:
data:
type: object
properties:
source_url:
anyOf:
- type: string
- type: 'null'
description: Final fetched URL, or null when html was supplied.
healed:
type: boolean
description: 'True when every field fills at least 4 in 5 records (single record: filled) and the data validates against targetSchema.'
decidedBy:
type: string
enum:
- previous_selectors
- repaired_selectors
- structured_markup
- llm
description: Which stage produced the returned spec; all but llm make no model call. With llm, only the fields in llmFields were sent to the model.
deterministic:
type: boolean
description: 'True when no model call was made: replay, cosmetic repair, or structured markup satisfied the schema.'
llmCalls:
type: integer
llmFields:
type: array
items:
type: string
description: Fields the model was asked to solve (empty when deterministic).
repairs:
type: array
description: 'Previous selectors changed to survive cosmetic drift: hashed or utility classes, :nth-child positions.'
items:
type: object
properties:
field:
type: string
from:
type: string
to:
type: string
strategy:
type: string
data:
description: Extracted data shaped like targetSchema.
selectorMap:
type: object
spec:
type: object
validation:
type: object
extractorCode:
type: string
description: Standalone TypeScript module exporting extract(html).
page_structure_notes:
type: string
_provenance:
type: object
description: C2PA-aligned manifest and W3C VC 2.0 (eddsa-jcs-2022) issued by the hub DID; verify at POST /api/v1/verify-provenance
required:
- data
- _provenance
'400':
description: Invalid request (no payment consumed)
content:
application/json:
schema:
type: object
properties:
error:
type: string
code:
type: string
'401':
description: Invalid X-API-KEY
content:
application/json:
schema:
type: object
properties:
error:
type: string
code:
type: string
'402':
description: Payment required or invalid
content:
application/json:
schema:
type: object
description: x402 v2 PaymentRequired (also base64 in the PAYMENT-REQUIRED header)
properties:
x402Version:
type: integer
error:
type: string
code:
type: string
resource:
type: object
accepts:
type: array
items:
type: object
extensions:
type: object
'502':
description: Upstream failure; the payment is released or not settled
content:
application/json:
schema:
type: object
properties:
error:
type: string
code:
type: string
tags:
- Heal Scraper
components:
securitySchemes:
x402:
type: apiKey
in: header
name: PAYMENT-SIGNATURE
description: x402 v2 payment payload (base64) sent after a 402 challenge
apiKey:
type: apiKey
in: header
name: X-API-KEY