Webhook events

Create an endpoint, verify the HMAC signature, read every event payload, and follow the retry schedule.

Updated 11 of 17 in API, MCP and integrations

Webhooks tell your system when an invite, a check, or an adverse-action case changes. Each delivery is an HTTPS POST signed with the endpoint secret.

Who it is for. A developer receiving events.

  1. Add an https URL and choose events on the API page, or call POST /api/v1/hooks.
  2. Copy the signing secret once. A later list of endpoints does not include it.
  3. Read X-PHB-Timestamp and X-PHB-Signature from the raw body, then compare the HMAC.
  4. Answer 2xx after you store the event. Anything else is retried.

Manage endpoints

On the API page, an owner or admin enters the URL and checks the events. check.completed starts checked. The same actions are available over the API.

CallScopeResult
GET /api/v1/hookschecks:read or webhooks:writehooks (id, url, events, is_active, created_at) and the event catalog
POST /api/v1/hookschecks:write or webhooks:writeid, url, events, and secret. The secret is not shown again.
DELETE /api/v1/hooks/:idchecks:write or webhooks:write{ ok: true }

POST body is { "url": "https://example.com/hooks", "events": ["check.completed"] }. Omit events and the subscription is only check.completed. An empty events array saves an endpoint that receives nothing. An unknown name is 400 with Unknown webhook event.

The URL must be public https. Localhost, .local, .internal, metadata hosts, and private, loopback, or link-local addresses are rejected with The webhook URL must be a public https address. Delete an endpoint to stop delivery. There is no pause call.

Verify a delivery

The POST has content-type: application/json and two headers:

  • X-PHB-Timestamp is Unix time in seconds.
  • X-PHB-Signature is the hex HMAC-SHA256 of timestamp + "." + raw body, using the signing secret. There is no prefix on the hex.

Reject the request when the timestamp is more than five minutes ahead or behind your clock. Compare the hex with a timing-safe compare, and use the raw body. Re-serializing the JSON changes the signature.

const crypto = require("crypto");

function verifyWebhook(secret, timestamp, rawBody, signature) {
  const issued = Number(timestamp);
  if (!Number.isFinite(issued)) return false;
  if (Math.abs(Date.now() / 1000 - issued) > 300) return false;
  const expected = crypto
    .createHmac("sha256", secret)
    .update(timestamp + "." + rawBody)
    .digest("hex");
  const left = Buffer.from(expected);
  const right = Buffer.from(signature);
  if (left.length !== right.length) return false;
  return crypto.timingSafeEqual(left, right);
}

A delivery succeeds on any HTTP 2xx. There is no delivery-id header. A retry sends the same JSON with a new timestamp and a new signature, so store event plus the ids in the body.

Event payloads

The JSON is the event name plus the fields below. Example: { "event": "check.completed", "checkId": "CHECK_ID" }. A test-key create does not emit any event. A duplicate in-flight invite does not emit invite.sent.

EventFieldsWhen
invite.sentinviteId, checkIdA new invite was created. checkId can be null.
invite.sentinviteUrlA CSV import sends the link instead of inviteId and checkId.
invite.completedcheckIdThe candidate submitted authorization.
invite.expiredcheckId, inviteIdThe invite expired and the credit was refunded.
check.completedcheckIdA clear report was released.
check.records_foundcheckIdA report with records was released.
check.report_revisedcheckId, outcomeA dispute replaced the report. Outcome is clear, records_found, or unverifiable.
check.unverifiablecheckIdThe check was refunded as unverifiable.
check.errorcheckIdThe screening call failed and the credit was refunded.
adverse_action.pre_notice_sentcheckIdThe pre-adverse notice went out.
adverse_action.response_receivedcheckIdThe candidate sent a response.
adverse_action.dispute_openedcheckIdA dispute paused the waiting period.
adverse_action.dispute_resolvedcheckIdA dispute was resolved.
adverse_action.final_notice_sentcheckIdThe final notice went out.
skills.completedinviteId, testId, scorePercentA candidate submitted a skills quiz. A test run does not emit this event. Answers are not included.
skills_test.sentinviteId, testIdA reviewed quiz was sent to a candidate. A test run does not emit this event.
skills_test.completedinviteId, testId, scorePercentSent with skills.completed when a candidate submits. A test run does not emit this event.
skills_test.expiredinviteIdA quiz link passed its open window.
course.assignedcourseSlugA practice course was assigned. A test assignment does not emit this event.
course.completedcourseSlugA person passed the practice exam. A test assignment does not emit this event.
job.publishedjob id, slug, and URLA person published a job. The payload has ids, the slug, and the public URL only.
job.closedjob id, slug, and URLA person closed a job. The payload has ids, the slug, and the public URL only.
application.receivedapplication id, job id, candidate id, and sourceSomeone applied. The payload has those ids and the source only.
candidate.createdcandidate_id, sourceA person was added. The payload has the candidate id and the source only.
candidate.stage_changedcandidate_id, from_stage, to_stage, sourceA person moved stage. The payload has those fields only.
integration.degradedconnection_id, providerA connection failed five times in a row. The owner also gets an email.
reference_request.sentrequest_id, statusA reference request was sent. status is awaiting_candidate. Names, contacts, and answers are not included.
reference_request.candidate_submittedrequest_id, statusThe candidate submitted their references. status is collecting.
reference.completedrequest_id, reference_id, statusA reference finished. status is completed. Answers are not included.
reference.declinedrequest_id, reference_id, statusA reference declined. status is declined.
reference_request.completedrequest_id, reference_id, statusEvery requested reference is in. status is complete.
reference_request.expiredrequest_id, statusThe request expired. status is expired.

sendInvite: false still emits invite.sent with inviteId and checkId. The candidate email or text is skipped, and your system sends inviteUrl from the create response.

Retries run past one day

A failed delivery waits 1 minute, 5 minutes, 30 minutes, 2 hours, 6 hours, 12 hours, and then 24 hours. The attempt after that last wait is the final one. If it fails, delivery stops.
A sample webhook endpoint.
A sample webhook endpoint.

See API keys and the invite model.

Was this article helpful?