Galon Cloud
Galon API v1

/search/v2/crawl/{crawl_id}

Base URL https://api.galon.ai/v1 · export GALON_API_BASE="https://api.galon.ai/v1"

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

NameInTypeDescription
crawl_idpathstring · required
skipqueryinteger

Responses

StatusDescriptionBody
200The jobCrawlStatusResponse
400query_invalidCrawlError
401api_key_missing, api_key_invalidCrawlError
403scope_missing (search:query)CrawlError
404not_found, crawl_not_found, crawl_expiredCrawlError
503search_unavailableCrawlError

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

NameInTypeDescription
crawl_idpathstring · required

Responses

StatusDescriptionBody
200The job's status after the requestCrawlCancelResponse
401api_key_missing, api_key_invalidCrawlError
403scope_missing (search:query)CrawlError
404not_found, crawl_not_foundCrawlError
503search_unavailableCrawlError

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>")