HTTP API

Routes for jobs, runs, events, views, and artifacts.

Base URL in local development is http://127.0.0.1:4340. Portal proxies the same routes under /api/scrape/*.

MethodPathPurpose
GET/api/scrape/healthRead server and dependency health.
POST/api/scrape/jobsCreate a scrape job from url, intent, auth, schema, budget, and emit options.
POST/api/scrape/jobs/:jobId/runStart the queued job and return a run id.
GET/api/scrape/runs/:runIdPoll an in-flight run or retrieve the terminal ScrapeResult.
GET/api/scrape/runs/:runId/eventsStream run events as SSE.
GET/api/scrape/runs/:runId/viewRead the latest markdown and annotated DOM view.
POST/api/scrape/runs/:runId/interactions/:interactionIdResolve an interaction-required pause.
GET/api/scrape/artifacts/:artifactIdRetrieve a reusable scrape artifact.
POST/api/scrape/artifacts/:artifactId/replayReplay and heal an artifact against a browser session.
GET/api/scrape/artifacts/:artifactId/downloadDownload artifact JSON.

Create and run a job

curl -sS http://127.0.0.1:4340/api/scrape/jobs \
  -H 'content-type: application/json' \
  -d '{"url":"https://example.com","intent":"extract the page title"}'

curl -sS -X POST http://127.0.0.1:4340/api/scrape/jobs/job_1/run