Overview & Quickstart

Overview

The AI Parser helps you to turn raw HTML responses from a website of your choice into clean, structured data. Feed it a few example URLs with the same structure: for example three product pages from a catalog. The AI Parser will generate a custom parser, that will extract the important data fields (or the ones you specify) from any similar page on that site (domain), automatically.

Base URL: https://aiparser.scraperapi.com

How it works in 3 steps

  1. Train - send a few example URLs (up to 3) of the same page type (e.g. three product pages) to POST /parsers

  2. Wait - the system generates a parser tailored to the page’s layout.

  3. Parse - send any similar URL to GET /parse/{parser_id} and get structured data back.

Authentication

Every endpoint needs an api_key. Pass it in the request body for POST/PATCH, or as a query parameter for GET/DELETE operations.

Quickstart

  1. Create a parser

curl -X POST https://aiparser.scraperapi.com/parsers \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Quotes_Parser",
    "api_key": "API_KEY",
    "urls": [
      "http://quotes.toscrape.com/page/1/",
      "http://quotes.toscrape.com/page/2/",
      "http://quotes.toscrape.com/page/3/"
    ]
  }'

Response

  1. Check the Parser's state

Example Responses

Generating

Failed

Finished

  1. Parse similar URL

Example Response

What's next

Last updated