Back to the help center

Integrations

Set up webhooks

Receive consent and scan events with signed webhooks

Last updated November 15, 2026

Available on the Business plan and above. See pricing for what each plan includes.

Receive events (consent choices, finished scans, banner changes) in your own systems. Webhooks are available on the Business plan and above, and creating one needs a verified email address.

Create a webhook

  1. Go to Webhooks → New Webhook.
  2. Enter your HTTPS endpoint URL.
  3. Select the events to receive, for example consent.accepted, consent.rejected, consent.updated or scan.completed.
  4. Choose how many times a failed delivery is retried (0 to 10).
  5. Save, then copy the signing secret. It is shown once, and every delivery is signed with it.

Validate requests

Every delivery is a JSON POST with an X-Webhook-Signature header of the form t=<unix seconds>,v1=<hex>. v1 is the HMAC-SHA256 of <t>.<raw request body> with your signing secret. Verify it over the bytes you received, before any JSON parsing, compare in constant time, and reject a delivery whose t is more than 5 minutes away from your clock so a captured request cannot be replayed:

import crypto from 'node:crypto';

function verifySignature(rawBody, header, secret) {
  const parts = (header || '').split(',').map((part) => part.trim().split('='));
  const timestamp = Number(parts.find(([key]) => key === 't')?.[1]);
  const signatures = parts.filter(([key]) => key === 'v1').map(([, value]) => value);
  if (!Number.isInteger(timestamp) || signatures.length === 0) return false;
  if (Math.abs(Date.now() / 1000 - timestamp) > 300) return false;
  const expected = crypto.createHmac('sha256', secret)
    .update(`${timestamp}.`).update(rawBody).digest('hex');
  return signatures.some((signature) => signature.length === expected.length &&
    crypto.timingSafeEqual(Buffer.from(signature), Buffer.from(expected)));
}

app.post('/webhooks/getcookies', express.raw({ type: 'application/json' }), (req, res) => {
  if (!verifySignature(req.body, req.get('X-Webhook-Signature'), process.env.GETCOOKIES_WEBHOOK_SECRET)) {
    return res.sendStatus(401);
  }
  const event = JSON.parse(req.body);
  res.sendStatus(204);
});
  • Respond with a 2xx status. A failed delivery is retried as many times as the endpoint allows, after 30 seconds, 2 minutes, 10 minutes, 30 minutes and 1 hour, then 2, 4, 8, 12 and 24 hours. A retry is signed again with a new t.

Privacy signal audit data

Every consent webhook includes privacy signal fields for compliance:

GPC (Global Privacy Control):

  • gpc.signal_detected: Was a GPC signal present?
  • gpc.honored: Did we apply the opt-out?
  • gpc.consent_source: banner, gpc_auto, api or inline_embed
  • gpc.region_code: User's jurisdiction (e.g., US-CA)

DNT (Do Not Track):

  • dnt.signal_detected: Was a DNT signal present?
  • dnt.honored: Was the signal honored?

Use these fields to prove compliance with the US state privacy laws that require honoring GPC signals (California, Colorado, Connecticut, Texas, Oregon and others).

Test safely

  • Point the endpoint at your staging server or a request inspector such as webhook.site.
  • Save a banner setting to receive widget.updated, or give consent on your own site to receive a consent event within about a minute.

Troubleshooting

  • If an endpoint keeps failing: after five failed deliveries in a row it is paused with a growing back-off (up to 6 hours). After three days without a successful delivery it is disabled, its pending deliveries are dropped and the owner gets an email. Fix the endpoint, then switch it back on in Webhooks.
  • If you get no events: check endpoint logs and firewalls, and confirm it returns a 2xx status. The delivery list for the endpoint shows each attempt with its HTTP status.
  • If you see duplicates: process idempotently with the X-Webhook-Delivery-Id header.
  • If signatures fail: verify the raw body, not re-serialized JSON, and check your server clock.
  • Rotate the secret if it is ever exposed (POST /api/v1/webhooks/{id}/regenerate-secret).

Still stuck?

Email [email protected] with your domain and what you tried. Signed-in customers can also open a ticket from the dashboard.