Extract Records by Declarative CSS Schema
extract_by_schemaDeterministic CSS-selector record extractor supporting descendant/child/attribute/group selectors, relative URL resolution against baseUrl, numeric currency/comma coercion, boolean flags, inner HTML serialization, and multi-value arrays. Pricing: $0.001 USD per declarative CSS-schema extraction (x402 instant micropayment). Pass ?dry_run=true on REST to validate schema free.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"html": "<html>",
"itemSelector": "<itemSelector>",
"fields": "<fields>"
},
"name": "extract_by_schema"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| html | Yes | Raw HTML page or fragment. | |
| fields | Yes | Map of output property names to declarative CSS selector + type coercion rules. | |
| baseUrl | No | Optional page URL used to resolve relative URLs when field type is 'url'. | |
| itemSelector | Yes | CSS selector matching each repeating record element (or 'body' / 'html' for single-object page extraction). |