Webhood exposes a REST API mounted atDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/webhood-io/webhood/llms.txt
Use this file to discover all available pages before exploring further.
/api/v1/, routed through Kong to the Go/PocketBase backend running at http://backend:8090. Kong forwards all /api/ traffic to the backend, making the API accessible on your host’s configured port. Every endpoint requires a valid Bearer token in the Authorization header — unauthenticated requests are rejected with 401 Unauthorized.
Base URL
<your-host> and <port> with the hostname and port of your Webhood deployment. In a default local setup this is typically http://localhost:8000/api/v1.
The
/api/beta/ prefix is the legacy endpoint that predates v1. It remains fully functional and uses the same underlying scan records, but /api/v1/ is the preferred path for all new integrations. Use v1 unless you have an existing integration pinned to beta.Available Endpoints
| Method | Path | Description |
|---|---|---|
GET | /api/v1/scans | List scans with optional filter, sort, limit, and offset |
POST | /api/v1/scans | Submit a new scan |
GET | /api/v1/scans/:id | Get a single scan record by ID |
GET | /api/v1/scans/:id/screenshot | Stream the screenshot image for a scan |
GET | /api/v1/scans/:id/html | Stream the captured HTML for a scan |
GET | /api/v1/scans/:id/trace | Stream the network trace JSON for a scan |
GET /api/v1/scans — Query Parameters
PocketBase filter expression, e.g.
status='done'. Supports standard field comparisons and logical operators.Comma-separated sort fields, e.g.
-created for descending by creation time.Maximum number of records to return. Omit to return all matching records.
Number of records to skip before returning results. Use with
limit for pagination.POST /api/v1/scans — Request Body
The fully-qualified URL to scan, e.g.
https://example.com.Optional scan configuration. See the
ScanOptions object below.HTTP Status Semantics
Scan records go through a lifecycle. The API reflects this in its HTTP response codes:| Status | Meaning |
|---|---|
202 Accepted | The scan is pending or running — poll again. A Location header points to the scan URL. |
200 OK | The scan is done or error — the full result is present in the response body. |
Scan Record Schema
Every endpoint that returns scan data uses the following JSON structure.PocketBase record ID — unique alphanumeric identifier for this scan.
Human-readable identifier composed of the scanned hostname and a Unix timestamp, e.g.
example.com-1714000000.The URL that was submitted for scanning.
Current lifecycle state of the scan. One of
pending, running, done, or error.ISO 8601 timestamp of when the scan record was created.
ISO 8601 timestamp of when the scan record was last updated.
Human-readable error details. Only populated when
status is error.File IDs for captured HTML artifacts. The first element (
html[0]) is the page HTML; the second (html[1]), when present, is the network trace JSON (also served by the /trace endpoint).File IDs for screenshot images captured during the scan.
File IDs for any additional artifacts attached to this scan record.
ISO 8601 timestamp of when the scan completed. Empty while the scan is still in progress.
The URL the browser landed on after following all redirects. May differ from
url when redirects occur.The
ScanOptions object that was used for this scan (see below).A
ScanDataV1_1 object containing detailed document, request, response, and metadata captured during the scan (see below).ScanOptions Object
ID of the scanner instance to run this scan. Omit to let Webhood assign one automatically.
Scanning speed vs. resource-wait tradeoff. One of
slow, balanced, or fast.Either the string
"full" for a full-page screenshot, or an object with width and height string fields specifying pixel dimensions.ScanData Object (ScanDataV1_1)
ThescanData field is only populated when the scan has status: "done". It follows schema version "1.1".
Schema version string. Always
"1.1" for current scans.Information about the scanned document.
The primary HTTP request made by the browser.
The HTTP response received for the primary request.
The
ScanOptions used for this scan (mirrors the top-level options field).A safe excerpt of the scanner’s configuration at the time of the scan. Sensitive fields such as API keys are excluded.
Scan execution metadata.