Skip to main content
DELETE
Cancel a crawl

Overview

Stops a crawl that is pending or running. The worker notices within a few pages and stops fetching. Nothing is thrown away: pages already crawled stay readable through GET /crawl/{id} until the crawl expires, 24 hours after it stopped. They are billed on the next status call as usual, so you pay for what was fetched and nothing more. Cancelling is free.

Example request

Example response

Behavior

  • Already finished? Cancelling a completed, failed, or cancelled crawl is a no-op. You get 200 with the crawl’s real final state rather than an error.
  • Not yet started? The queued job is removed, so no pages are ever fetched.
  • Unknown or expired id? 404.
A crawl you do not own also returns 404 rather than 403. Crawl ids are unguessable, and confirming that some id exists is the only thing an enumeration attempt is after.

POST /crawl

Start a crawl.

GET /crawl/{id}

Read progress and results.

Authorizations

X-API-Key
string
header
required

Your Prefetch API key. Obtain one from the dashboard.

Path Parameters

id
string
required

The crawl id returned by POST /crawl.

Example:

"crw_9f2c1a7b4e0d4c3a8b1e5f7d2c9a0b3e"

Response

Crawl cancelled, or already finished.

success
enum<boolean>
required
Available options:
true
data
object
required
meta
object
required