GET /search/v2/crawl/{crawl_id}
Read a crawl job: status and pages
Status (scraping, completed, failed, cancelled), counters and the pages read, 20 per answer; follow `next` while present. A job whose results expired (24 hours) is 404 crawl_expired. Not counted.
API key (Bearer), on the public API endpoint.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
crawl_id | path | string · required | |
skip | query | integer |
Responses
| Status | Description | Body |
|---|---|---|
200 | The job | CrawlStatusResponse |
400 | query_invalid | CrawlError |
401 | api_key_missing, api_key_invalid | CrawlError |
403 | scope_missing (search:query) | CrawlError |
404 | not_found, crawl_not_found, crawl_expired | CrawlError |
503 | search_unavailable | CrawlError |
Examples
curl
curl -X GET "$GALON_API_BASE/search/v2/crawl/<crawl_id>" \
-H "Authorization: Bearer $GALON_API_KEY"Node.js (SDK)
import { Galon } from "galon";
const galon = new Galon(process.env.GALON_API_KEY);
const result = await galon.search.getCrawl("<id>");Python (SDK)
from galon import Galon
galon = Galon() # reads GALON_API_KEY
result = galon.search.get_crawl("<id>")DELETE /search/v2/crawl/{crawl_id}
Cancel a running crawl job (see also GET …/errors below)
Stops a job that is queued or scraping; the pages already read stay readable until they expire. A finished job is returned as it is.
API key (Bearer), on the public API endpoint.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
crawl_id | path | string · required |
Responses
| Status | Description | Body |
|---|---|---|
200 | The job's status after the request | CrawlCancelResponse |
401 | api_key_missing, api_key_invalid | CrawlError |
403 | scope_missing (search:query) | CrawlError |
404 | not_found, crawl_not_found | CrawlError |
503 | search_unavailable | CrawlError |
Examples
curl
curl -X DELETE "$GALON_API_BASE/search/v2/crawl/<crawl_id>" \
-H "Authorization: Bearer $GALON_API_KEY"Node.js (SDK)
import { Galon } from "galon";
const galon = new Galon(process.env.GALON_API_KEY);
const result = await galon.search.cancelCrawl("<id>");Python (SDK)
from galon import Galon
galon = Galon() # reads GALON_API_KEY
result = galon.search.cancel_crawl("<id>")