Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API 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. By signing up you are subscribing to the APIs.io and API Evangelist
newsletters — you can unsubscribe from any issue. See our
Privacy Policy and Terms.
openapi: 3.2.0
info:
title: scrapewright Crawl API
description: Give it a URL, it writes the scraper. An LLM compiles a site once; every page after that replays free.
version: 1.0.3
tags:
- name: Crawl
paths:
/v1/crawl:
post:
summary: Crawl Endpoint
description: Walk a whole site. Returns a job id — crawls outlive a request.
operationId: crawl_endpoint_v1_crawl_post
parameters:
- name: x-api-key
in: header
required: false
schema:
type: string
default: ''
title: X-Api-Key
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/CrawlRequest'
responses:
'202':
description: Successful Response
content:
application/json:
schema:
type: object
additionalProperties: true
title: Response Crawl Endpoint V1 Crawl Post
'422':
description: Validation Error
content:
application/json:
schema:
$ref: '#/components/schemas/HTTPValidationError'
tags:
- Crawl
components:
schemas:
ValidationError:
properties:
loc:
items:
anyOf:
- type: string
- type: integer
type: array
title: Location
msg:
type: string
title: Message
type:
type: string
title: Error Type
input:
title: Input
ctx:
type: object
title: Context
type: object
required:
- loc
- msg
- type
title: ValidationError
HTTPValidationError:
properties:
detail:
items:
$ref: '#/components/schemas/ValidationError'
type: array
title: Detail
type: object
title: HTTPValidationError
CrawlRequest:
properties:
url:
type: string
title: Url
fields:
anyOf:
- items:
type: string
type: array
- type: 'null'
title: Fields
description: Custom schema, e.g. ['title', 'salary:number', 'tags:list']. Omit for the built-in product schema.
js:
type: boolean
title: Js
description: Render in a headless browser.
default: false
retry:
type: boolean
title: Retry
description: Try compiling a site that failed before. A site nobody could read is remembered for a week and answered without calling the model, so a daily refresh of a dead link costs nothing; this asks anyway.
default: false
max_items:
type: integer
title: Max Items
default: 25
mode:
type: string
title: Mode
description: 'How to find the items. ''links'': follow links from a listing into item pages. ''rows'': the listing''s own cards are the rows, walking its pagination. ''like'': the URL is one item page; find every other page shaped like it.'
default: links
listing_url:
anyOf:
- type: string
- type: 'null'
title: Listing Url
description: 'For mode=''like'': the stock, catalogue or results page these items are listed on, e.g. https://dealer.nl/occasions. Guessing it is the part that fails, so say it when you know it; the walk starts there and follows its pagination.'
rows:
type: boolean
title: Rows
description: Shipped before `mode` existed; true means mode='rows'.
default: false
deprecated: true
scroll:
type: integer
maximum: 50.0
minimum: 0.0
title: Scroll
description: 'For listings that load more as you scroll: how many times to scroll before reading. Needs js=true. Scrolling stops early when the page stops growing, so a generous number costs nothing on a page that does not need it.'
default: 0
type: object
required:
- url
title: CrawlRequest