Extract precise fields
Define CSS selectors for the names, headings or values your application needs. Give each field a stable name so downstream code does not depend on the complete page markup.
Web Scraping API
Render JavaScript pages in a browser and extract a defined set of fields. Give your pipeline structured results instead of another page to parse.
01 / OVERVIEW
AdsCrawl Web Scraping API extracts specified fields from browser-rendered websites through POST /spa-extract. Define fields using DOM selectors or supported network response sources. When you need rendered markup or readable page content instead, use POST /html with the appropriate output mode.
02 / USE CASES
Define CSS selectors for the names, headings or values your application needs. Give each field a stable name so downstream code does not depend on the complete page markup.
Use supported network fields when the page retrieves JSON while loading. Consult the API reference for matching and extraction rules.
Inspect missingFields alongside returned data. Detect changed selectors and incomplete loads before storing results in a monitoring or research pipeline.
03 / QUICKSTART
Requires Bash and cURL. Set the ADSCRAWL_API_KEY environment variable on your server first.
Full request and response reference →curl --fail-with-body -sS \
-X POST "https://api.adscrawl.net/spa-extract" \
-H "x-api-key: $ADSCRAWL_API_KEY" \
-H "content-type: application/json" \
-d '{
"url": "https://www.adscrawl.net",
"mode": "extract",
"fields": {
"title": {
"source": "dom",
"selector": "h1",
"parse": "string"
}
}
}'Keep API keys on the server. For HTTP 402 check your balance; for 429 reduce concurrency and retry with backoff.
05 / FAQ
Use /html for rendered HTML or readable article content. Use /spa-extract when you need a specified set of DOM or supported network fields.
Inspect missingFields and the returned data. Check the current selector and wait settings, then update your field definition if the target site's structure has changed.
No. Validate required fields, types and any business rules before storing the result. Rendering and extraction do not establish that the source's claims are accurate.