Skip to content

API documentation

The Vaicrawl API lives under /v1/ and speaks JSON. Everything you can do in the interface you can also do here.

The OpenAPI schema (YAML) The OpenAPI schema (JSON)

Common rules

Authentication
Every request carries an API key in the Authorization header: Bearer followed by the key. Keys are created on the "API keys" page, and each one has its own scopes.
Authorization: Bearer vc_…
Errors
Every error has the same shape, with a stable code in English to decide on and a message in the language of Accept-Language.
{"error": {"code": "…", "message": "…", "detail": {}}}
Pagination
Lists are paginated with a cursor: follow the "next" address until it is empty. The limit parameter sets how many items per page, up to 200.
Idempotency
Every POST that creates something accepts the Idempotency-Key header: the same key within 24 hours returns the same response instead of creating a second object.
Rate limits
Each key has a limit of requests per minute, stated by the RateLimit-Limit, RateLimit-Remaining and RateLimit-Reset headers. Over the limit the response is 429, with Retry-After.

Endpoints

GET /v1/archive/retention

Get the HTML retention

The retention in force, the maximum allowed by the plan and the choice of the customer, in days.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

PUT /v1/archive/retention

Set the HTML retention

For how many days the HTML of a capture is kept, within the maximum of the plan; older HTML is pruned once a day, and the text, dates and hashes stay.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

GET /v1/billing

Get the subscription

The plan, the notice mode, the status of the subscription and what the customer can do (full, read_only, suspended), with the dates of a failed payment. Buying and changing the plan happen on the Stripe pages, from the web interface.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

GET /v1/captures

List captures

The archive of the customer, newest first: every capture, filtered by label, by exact URL, or from a moment on.

Requires an API key. Parameters: cursor, label, limit, since, url. Responses: 200, 400, 401, 403, 404, 429

GET /v1/captures/{capture_id}

Get a capture

One capture of the customer, with its text; 404 if it is not there.

Requires an API key. Parameters: capture_id. Responses: 200, 400, 401, 403, 404, 429

GET /v1/captures/{capture_id}/diff

Compare two captures of the same URL

The changes between two captures of the same URL, block by block, with the text before, the text after and the words around. "before" is always the capture downloaded first, whichever is in the path. 400 different_pages if the URLs differ.

Requires an API key. Parameters: capture_id, with. Responses: 200, 400, 401, 403, 404, 429

GET /v1/captures/{capture_id}/html

Download the HTML of a capture

The archived HTML, as a text/plain attachment: it is third-party content and is never served as a page. 404 html_not_available if the job did not keep it or it has been pruned.

Requires an API key. Parameters: capture_id. Responses: 200, 400, 401, 403, 404, 429

POST /v1/captures/{capture_id}/reextract

Reread a capture with the current extractor

Reads the archived HTML again with the current extractor, without downloading anything. The capture is never changed: if the document differs, a new capture is created (201), marked with reextracted_from; if it is the same, nothing is created (200, outcome unchanged). 404 html_not_available if the HTML was not kept or has been pruned. Counts one "rereads" unit. Accepts Idempotency-Key.

Requires an API key. Parameters: capture_id. Responses: 200, 201, 402, 400, 401, 403, 404, 429

POST /v1/captures/import

Import historical captures

Adds up to 100 captures read elsewhere: text, optional HTML (archived like any other), the date the page was read and the extractor version. Nothing is downloaded. All or nothing: one invalid capture rejects the request. The new HTML counts in "archived_bytes". Accepts Idempotency-Key.

Requires an API key. Responses: 201, 402, 400, 401, 403, 404, 429

POST /v1/captures/reextract

Reread many captures

Rereads up to 500 captures with the current extractor, in the given order, removing the lines already found on the pages reread before (deduplicate, as a crawl does). Each capture gets its own outcome; a capture of another customer makes the whole request 404, before anything is written. Counts one "rereads" unit per capture with HTML. Accepts Idempotency-Key.

Requires an API key. Responses: 200, 402, 400, 401, 403, 404, 429

GET /v1/changes/{change_id}/items

List the new items of a change

The new items of a feed, sitemap or list_page change, with the text read from their page and their linked documents (PDF, DOCX, XLSX…). Third-party content.

Requires an API key. Parameters: change_id, cursor, limit. Responses: 200, 400, 401, 403, 404, 429

GET /v1/connections

List connections

The connections of the customer, newest first. Secrets are never returned.

Requires an API key. Parameters: cursor, limit. Responses: 200, 401, 403, 404, 429

POST /v1/connections

Create a connection

Creates a connection to a connector, with its configuration (secrets included, write-only). Address fields are checked against the SSRF rules. The new connection is "unverified": verify it before use. If the connector has activation-only fields (`activation_only` in GET /v1/connectors), they are used to verify it right away and never stored: `status` and `last_error` say how it went. Supports Idempotency-Key.

Requires an API key. Responses: 201, 400, 401, 403, 404, 409, 429

GET /v1/connections/{public_id}

Retrieve a connection

One connection of the customer, without its secrets; 404 if it is not there.

Requires an API key. Parameters: public_id. Responses: 200, 401, 403, 404, 429

PATCH /v1/connections/{public_id}

Update a connection

Changes the name or some configuration fields. A missing or empty secret is kept as it is. Changing the configuration makes the connection "unverified" again. Writing an activation-only field reactivates the connection: it is verified right away with it, and the field is never stored.

Requires an API key. Parameters: public_id. Responses: 200, 400, 401, 403, 404, 409, 429

DELETE /v1/connections/{public_id}

Delete a connection

Deletes the connection and its secrets. The change log is kept.

Requires an API key. Parameters: public_id. Responses: 204, 401, 403, 404, 429

GET /v1/connections/{public_id}/changes

The change log of a connection

Who created, changed, verified, deactivated or deleted the connection, and when. Field names only: never values.

Requires an API key. Parameters: cursor, limit, public_id. Responses: 200, 401, 403, 404, 429

POST /v1/connections/{public_id}/deactivate

Deactivate a connection

The connection is no longer used; it stays in the list, deactivated. 404 if it is not there.

Requires an API key. Parameters: public_id. Responses: 200, 401, 403, 404, 429

POST /v1/connections/{public_id}/reactivate

Reactivate a connection

A reactivated connection is "unverified": verify it again before use.

Requires an API key. Parameters: public_id. Responses: 200, 401, 403, 404, 429

POST /v1/connections/{public_id}/test-message

Send a test message

Sends a real test email through the connection, to the email of the account (never to another address). The connection must be verified.

Requires an API key. Parameters: public_id. Responses: 200, 400, 401, 403, 404, 409, 429

POST /v1/connections/{public_id}/verify

Verify a connection

Checks the credentials with the lightest call the provider offers. A failed verification is not an error of the request: the answer says ok=false, with the cause in words.

Requires an API key. Parameters: public_id. Responses: 200, 400, 401, 403, 404, 409, 429

GET /v1/connectors

Available connectors

The connectors a connection can use, with the configuration fields each one asks for (labels in the language of Accept-Language). Secret fields are write-only. Use it to build your own form.

Requires an API key. Responses: 200, 401, 429

GET /v1/credits

Get the credits

The credit balance and the choices: overage (off at first) with its monthly cap, and auto recharge. Beyond the monthly quotas of the plan, units are paid with credits only if overage is on, within the cap and the balance.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

PATCH /v1/credits

Change the credit choices

Changes only the fields sent. Overage needs a plan that includes it; auto recharge needs a saved card, a pack and a threshold above 0.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

POST /v1/credits/checkout

Buy a credit pack

Returns the Stripe Checkout page for a pack, to open in a browser. Nothing is credited until Stripe confirms the payment. Accepts Idempotency-Key.

Requires an API key. Responses: 201, 503, 400, 401, 403, 404, 429

GET /v1/credits/packs

List credit packs

The credit packs for sale, from the price list of the installation.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

GET /v1/credits/transactions

List credit transactions

The credit transactions of the customer, newest first.

Requires an API key. Parameters: cursor, kind, limit, month. Responses: 200, 400, 401, 403, 404, 429

GET /v1/credits/transactions/{transaction_id}

Get a credit transaction

One credit transaction of the customer; 404 if it is not there.

Requires an API key. Parameters: transaction_id. Responses: 200, 400, 401, 403, 404, 429

POST /v1/design-fingerprints

Measure the design of a page

Opens the page in a browser at the given width and measures its design: colours, typography, spacing, components, layout bands. Runs as a job of kind design: read the result in GET /v1/jobs/{id} (result: markdown, files, bands, summary). robots.txt is always respected. Counts one page. Accepts Idempotency-Key.

Requires an API key. Responses: 202, 402, 400, 401, 403, 404, 429

GET /v1/events

Replay events

The events of the customer, oldest first: use it to catch up on what a webhook missed. Each item has the same shape as the body of a delivery.

Requires an API key. Parameters: cursor, limit, since, type. Responses: 200, 400, 401, 403, 404, 429

GET /v1/extractor

Get the extractor version

The version of the text extractor that reads the pages now.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

GET /v1/gift-codes

List the gift codes bought

The gift codes bought by the customer, newest first. The code itself is shown only while it can be redeemed.

Requires an API key. Responses: 200, 400, 401, 403, 429

POST /v1/gift-codes

Buy a gift code

Returns the Stripe Checkout page to buy a gift code of a credit pack. The code is created when Stripe confirms the payment; it can be redeemed once, within 12 months. Accepts Idempotency-Key.

Requires an API key. Responses: 201, 503, 400, 401, 403, 429

GET /v1/jobs

List jobs

The jobs of the customer, newest first.

Requires an API key. Parameters: cursor, label, limit, status. Responses: 200

POST /v1/jobs

Start a job

Starts a job: a site crawled from start_url, or a list of urls (one page each). Limits are applied on the server: max_depth 0-10, max_pages 1-500. An unknown option is an error. Requires a verified email. Accepts Idempotency-Key. A plan allows a number of open jobs (running and waiting): one more answers 429 too_many_jobs. A job whose pages times the delay between pages exceeds the maximum duration of a job answers 400 job_too_long, with the figures in detail. Waiting jobs start in turn, a few per customer at a time.

Requires an API key. Responses: 201, 402, 400, 401, 403, 404, 429

GET /v1/jobs/{job_id}

Get a job

The state and progress of one job of the customer; 404 if it is not there.

Requires an API key. Parameters: job_id. Responses: 200, 400, 401, 403, 404, 429

POST /v1/jobs/{job_id}/cancel

Cancel a job

A queued job is cancelled at once; a running job stops before its next page and keeps the pages already downloaded. Cancelling a finished job changes nothing.

Requires an API key. Parameters: job_id. Responses: 200, 400, 401, 403, 404, 429

GET /v1/jobs/{job_id}/captures

List the captures of a job

Every page the job downloaded: new captures, and earlier captures of the same label found again with the same text (no new capture is made for an unchanged page).

Requires an API key. Parameters: cursor, job_id, limit. Responses: 200, 400, 401, 403, 404, 429

GET /v1/jobs/{job_id}/failures

List the failures of a job

The pages of the job that did not enter the archive, with the reason; 404 for a job that is not there.

Requires an API key. Parameters: cursor, job_id, limit. Responses: 200, 400, 401, 403, 404, 429

DELETE /v1/labels/{label}

Delete everything with a label

Deletes the jobs, captures and failures with this label, releasing their HTML (deleted when no other capture uses it), and the data of every other part of the service that keeps labels. Only the data of the customer of the key. Deleting twice is not an error: the second time deletes nothing. The label may contain slashes.

Requires an API key. Parameters: label. Responses: 200, 400, 401, 403, 404, 429

GET /v1/lists

List subscriber lists

The subscriber lists of the customer, newest first.

Requires an API key. Parameters: cursor, label, limit. Responses: 200

POST /v1/lists

Create a subscriber list

Creates a list. Lists exist only when Vaicrawl sends the notices: choose the mode service or own_provider first (PATCH /v1/notice-settings). An unknown field is an error. Requires a verified email. Accepts Idempotency-Key.

Requires an API key. Responses: 201, 400, 401, 403, 404, 429

GET /v1/lists/{list_id}

Get a subscriber list

The list, with the number of its subscribers by status.

Requires an API key. Parameters: list_id. Responses: 200, 400, 401, 403, 404, 429

PATCH /v1/lists/{list_id}

Update a subscriber list

Changes only the fields sent. Languages, topics and templates are checked together: removing a language still used by a topic name or by a template is an error.

Requires an API key. Parameters: list_id. Responses: 200, 400, 401, 403, 404, 429

DELETE /v1/lists/{list_id}

Delete a subscriber list

Deletes the list and its subscribers. Suppressions stay: they belong to the customer, not to the list.

Requires an API key. Parameters: list_id. Responses: 204, 400, 401, 403, 404, 429

GET /v1/lists/{list_id}/subscribers

List subscribers

The subscribers of the list, newest first. Tokens are never returned.

Requires an API key. Parameters: cursor, limit, list_id, status. Responses: 200, 400, 401, 403, 404, 429

POST /v1/lists/{list_id}/subscribers

Import subscribers

Adds addresses to the list. You must declare how you collected their consent. Every imported subscriber stays pending and receives a confirmation request: no notice is sent to an address that has not confirmed. Suppressed addresses (people who unsubscribed) are skipped and never come back. Sending the same request twice is safe: an address already in the list is skipped as already_present. Requires a verified email.

Requires an API key. Parameters: list_id. Responses: 200, 400, 401, 403, 404, 429

GET /v1/me

The customer of the API key

Returns the customer the API key belongs to, and the key itself (never the secret: only its prefix and scopes). Any valid key can call it: use it to check a newly configured key.

Requires an API key. Responses: 200, 401, 403, 429

GET /v1/monitors

List monitors

The monitors of the customer, newest first.

Requires an API key. Parameters: cursor, kind, label, limit. Responses: 200

POST /v1/monitors

Create a monitor

Creates a monitor. The first check only records a baseline: changes are reported from the second one. An unknown field is an error. Requires a verified email. Accepts Idempotency-Key.

Requires an API key. Responses: 201, 400, 401, 403, 404, 429

GET /v1/monitors/{monitor_id}

Get a monitor

One monitor of the customer; 404 if it is not there.

Requires an API key. Parameters: monitor_id. Responses: 200, 400, 401, 403, 404, 429

PATCH /v1/monitors/{monitor_id}

Update a monitor

Changes only the fields sent. Changing url, kind or a selector restarts the comparison: the next check records a new baseline.

Requires an API key. Parameters: monitor_id. Responses: 200, 400, 401, 403, 404, 429

DELETE /v1/monitors/{monitor_id}

Delete a monitor

Deletes the monitor, its changes and their items.

Requires an API key. Parameters: monitor_id. Responses: 204, 400, 401, 403, 404, 429

GET /v1/monitors/{monitor_id}/changes

List the changes of a monitor

The changes found by a monitor, newest first; 404 for a monitor that is not there.

Requires an API key. Parameters: cursor, limit, monitor_id. Responses: 200, 400, 401, 403, 404, 429

POST /v1/monitors/{monitor_id}/check

Check a monitor now

Queues a check now. The answer is the monitor as it is when the check is queued; its outcome arrives as change.detected or monitor.failing, and in last_outcome. A check already running is not repeated.

Requires an API key. Parameters: monitor_id. Responses: 202, 400, 401, 403, 404, 429

GET /v1/notice-settings

Get the notice settings

How notices reach your recipients. Without a choice, the mode is customer: you receive the events and send yourself. status says whether the queued notices can leave now, and if not, why, in the language of Accept-Language.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

PATCH /v1/notice-settings

Change the notice settings

Changes only the fields sent. The mode must be included in your plan. A connection is used only by the modes bulk and own_provider, and must be of the matching type. fallback_to_service is never set for you: the moment and the author of the authorization are recorded. bulk_target (mode bulk only) is checked with your provider when the connection is verified: an unknown list or segment is a validation_error, and nothing is saved. Changing the mode or the connection clears bulk_target. meaning chooses the language model that matches the new items by meaning (off, service, or your own connection of type language_model). The response carries the status of the queue.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

GET /v1/notice-settings/provider-lists

List the lists of your provider

Mode bulk only: the lists of your bulk sender, read now through the connection of your notice settings, so you can choose the list_id of bulk_target. Without the mode bulk and a bulk connection: 409 no_list_connection. With the connection disabled or unverified: 409 connection_disabled or connection_not_verified. When the provider does not answer: 502 provider_failed, with the cause in detail.cause.

Requires an API key. Responses: 200, 401, 403, 404, 409, 429, 502

GET /v1/notice-settings/provider-lists/{list_id}/segments

List the segments of a list of your provider

The segments (or tags) of one list of your bulk sender, to choose the segment_id of bulk_target. A list the provider does not give to your connection is 404. The other errors are those of the lists.

Requires an API key. Parameters: list_id. Responses: 200, 401, 403, 404, 409, 429, 502

GET /v1/notices

List the notices sent

The notices Vaicrawl created for your recipients (modes bulk, service and own_provider), newest first: one per new item and list, with how many dispatches are in each status. A list_id of another customer is 404.

Requires an API key. Parameters: cursor, limit, list_id. Responses: 200, 400, 401, 403, 404, 429

GET /v1/notices/{notice_id}

Get a notice

The notice, with how many dispatches are in each status.

Requires an API key. Parameters: notice_id. Responses: 200, 400, 401, 403, 404, 429

GET /v1/notices/{notice_id}/deliveries

List the deliveries of a notice

One row per recipient (in mode bulk, one for the list of your provider), newest first, with the status, the error if any, and why the recipient gets the notice, in the language of Accept-Language. A notice of another customer is 404.

Requires an API key. Parameters: cursor, limit, notice_id, status. Responses: 200, 400, 401, 403, 404, 429

POST /v1/probe

Diagnose an address

What robots.txt says (crawl delay, sitemaps, whether the address is allowed) and what the site answers to a real browser (status, headers, browser check, title, characters). Runs as a job of kind probe: read the result in GET /v1/jobs/{id} (result: robots, request). A page forbidden by robots.txt is not downloaded. Counts one page if it is downloaded. Accepts Idempotency-Key.

Requires an API key. Responses: 202, 402, 400, 401, 403, 404, 429

GET /v1/promotions

List the benefits of the customer

The benefits obtained from promotions, staff awards and gift codes: what is left and until when. The valid ones first, then the last 20 ended.

Requires an API key. Responses: 200, 400, 401, 403, 429

POST /v1/promotions/redeem

Redeem a code

Redeems a promotion code or a gift code. A refused code answers 400 with the reason as error code (invalid_code, code_expired, code_used, promotion_not_available, not_eligible, already_obtained, promotion_sold_out); too many attempts answer 429 throttled.

Requires an API key. Responses: 200, 400, 401, 403, 429

GET /v1/services

List paid services

The paid services: what the plan includes and what is switched on.

Requires an API key. Responses: 200, 400, 401, 403, 404, 429

GET /v1/services/{code}

Get a paid service

One paid service of the catalogue, with its state for the customer; 404 for a code that is not in the catalogue.

Requires an API key. Parameters: code. Responses: 200, 400, 401, 403, 404, 429

PATCH /v1/services/{code}

Switch a paid service

Switches a service on or off. A subscription item cannot be switched (409 service_not_switchable); a service outside the plan cannot be switched on (409 service_not_in_plan, with the plans that include it).

Requires an API key. Parameters: code. Responses: 200, 409, 400, 401, 403, 404, 429

DELETE /v1/subscribers/{subscriber_id}

Delete a subscriber

Deletes the subscriber. It is not an unsubscription: no suppression is created, and an existing one stays.

Requires an API key. Parameters: subscriber_id. Responses: 204, 400, 401, 403, 404, 429

GET /v1/usage

Get the usage of a month

The usage of the customer in a month (UTC), unit by unit, with the quota of the plan. Quotas are checked before spending: a job stops when its pages would exceed the quota of pages.

Requires an API key. Parameters: month. Responses: 200, 400, 401, 403, 429

GET /v1/webhooks

List webhooks

The webhooks of the customer, newest first.

Requires an API key. Parameters: cursor, limit. Responses: 200

POST /v1/webhooks

Create a webhook

Creates a webhook. The URL must be https:// on port 443 and resolve to public addresses only. The response contains the signing secret, shown only once. Accepts Idempotency-Key.

Requires an API key. Responses: 201, 400, 401, 403, 404, 429

GET /v1/webhooks/{webhook_id}

Get a webhook

One webhook endpoint of the customer; 404 if it is not there.

Requires an API key. Parameters: webhook_id. Responses: 200, 400, 401, 403, 404, 429

PATCH /v1/webhooks/{webhook_id}

Update a webhook

Changes only the fields sent. The secret never changes.

Requires an API key. Parameters: webhook_id. Responses: 200, 400, 401, 403, 404, 429

DELETE /v1/webhooks/{webhook_id}

Delete a webhook

Deletes the webhook and its delivery log.

Requires an API key. Parameters: webhook_id. Responses: 204, 400, 401, 403, 404, 429

GET /v1/webhooks/{webhook_id}/deliveries

List deliveries

Every delivery attempt of the webhook, newest first.

Requires an API key. Parameters: cursor, limit, webhook_id. Responses: 200, 400, 401, 403, 404, 429

POST /v1/webhooks/{webhook_id}/test

Send a test event

Queues a webhook.test event for this webhook only, even if it is disabled or does not subscribe to it. Follow the result in the delivery log.

Requires an API key. Parameters: webhook_id. Responses: 202, 400, 401, 403, 404, 429