Skip to main content

Webhooks

Webhooks deliver signed callbacks to your server. They’re used for asynchronous crawl.completed notifications and can be tested manually before going live.
Authentication: API key required.

Signature verification

Every webhook is signed with HMAC-SHA256. The signature is computed over the canonical JSON of the payload (stable key order, compact separators) and sent in two places:
  1. The X-BaaS-Signature header — sha256=<hex>
  2. The signature field in the JSON body
Node.js — verify a signature
Python — verify a signature

Test a webhook

POST /v1/webhooks/test sends a single immediate signed webhook to your URL (no retry) and records the attempt in your delivery logs.

Body

Response — 200 OK
If delivery fails, the endpoint returns 502 with detail.error: webhook_delivery_failed.

View delivery logs

GET /v1/webhooks/logs lists your delivery records, newest first.
Response

Crawl completion callback

When a crawl job with a callback_url completes, X1-BaaS dispatches a signed crawl.completed webhook:
Example payload

Retry behavior

Crawl-completion webhooks retry with exponential backoff: After the retry budget (3 retries after the initial attempt) the delivery is marked failed.
Always verify the X-BaaS-Signature header with a constant-time comparison before trusting a webhook payload.