Skip to main content
A webhook tells your own system when something happens in your workspace. You register an HTTPS address and choose the events. ImpelLabs sends each event to that address as a signed JSON request. Only an owner or an admin can read or change webhooks. Every other member gets a 403 with the message Only an owner or an admin can see and change webhooks.

Register an address

List the events you can choose first. The reply holds the name and a plain label of each event. The event types page describes the data each event carries.
Then register the address.
The reply is the webhook. It carries the signing secret once. Store it now: no other call shows it again.
You can keep a limited number of webhooks in one workspace. Remove one you do not use before you add another. A live webhook gets the events of your workspace. A staging webhook gets only test events and the live deliveries you replay to it, so a receiver under test never sees real traffic.

What ImpelLabs sends

Each delivery is a POST with a JSON body and these headers. The body has the same shape for every event.
data holds the fields of the event. Names that start with an underscore never leave ImpelLabs.

Check the signature

The signature follows the Standard Webhooks scheme. Check it before you trust a request.
  1. Take the text after whsec_ in your secret and decode it from base64. The result is the key.
  2. Build the signed text: the webhook-id, a dot, the webhook-timestamp, a dot, and the raw request body.
  3. Compute an HMAC with SHA-256 over that text with the key. Encode the result in base64.
  4. Compare it with each value in webhook-signature. Each value starts with v1,. The header can hold more than one value, separated by spaces. One match is enough.
Use the raw body, before any JSON parsing. Reject a request when the timestamp is far from your clock. Use the webhook-id to drop an event you already handled.

Retries

Answer with a 2xx status within 10 seconds. Any other answer is a failed try.
  • A network error, a time-out, 408, 429 and every 5xx status are tried again. The waits are 1 minute, 5 minutes, 30 minutes and 2 hours. A delivery gets five tries in all.
  • Any other 4xx status is final. ImpelLabs does not try again, because your receiver said no.
  • A delivery that waits for the rate limit does not use a try. A limit never drops an event.
  • When 15 deliveries fail one after another, ImpelLabs switches the webhook off. It sets off_reason, and the owners and admins get a notice. Fix the address, then send {"on": true} to switch it on. The failure count starts again.
Test deliveries and replays are sent once and are not tried again.

Rotate the secret

The reply is {"secret": "whsec_..."}. For 24 hours both the new and the old secret sign each delivery, so webhook-signature holds two values. old_secret_until shows when the old secret stops. Update your receiver in that time.

Test, read and replay

The deliveries list is {"results": [...], "next": "..."}. Pass next as ?before= to read older ones. Each delivery shows status (pending, sent or failed), attempts, next_at, response_status, error, test and the sent payload. A delivery that is still pending cannot be redelivered: the call returns 409. Replay to a live webhook is refused.

Change or remove a webhook

PATCH /api/v1/webhooks/{endpoint_id} takes any of url, description, events, on (true or false) and rate_per_minute. DELETE removes the webhook and stops its pending deliveries. Every call has its own page in the API reference group of this tab.