Skip to main content
When someone leaves, you need to revoke access, end coverage, and tell downstream vendors - each on its own date.

What you’ll use

Models - employee, employment, benefit, dependent benefit Events - employee_data_changed, connector_synced, connector_sync_error
Before you start
  • A webhook is registered for the environment - see Create a Webhook.
  • You can schedule work for a future date. Every action here is gated on a date, not on arrival.

Steps

1

Subscribe to employee changes

Subscribe to employee_data_changed. Add connector_sync_error too - a connector that stops syncing stops reporting terminations, and silence is the failure mode here.Result: IDs of employees whose records changed.
2

Fetch the changed employees

employment_status, termination_date and termination_reason all sit on the employee, so one call carries everything the decision needs.Result: Status and termination details in one response.
3

Match every terminal status

Four statuses are departures, and one that looks like a departure isn’t.
INACTIVE_EXTERNAL is a contractor ending an engagement. Matching only on INACTIVE silently misses them - see Filtering for the full enum.Result: Every real departure, and no false ones.
4

Schedule on the termination date

Terminations are recorded when they’re entered, often weeks before they take effect. Act on the date, not on the event.
Keep the scheduled action cancellable. Rescinded resignations, entry errors and quick rehires are common enough that destructive-on-arrival costs more than it saves - see Unexpected records.Result: Access ends on the last day, not the day HR typed it in.
5

Read coverage end dates separately

Employment ending does not end coverage. Read the benefit records to find when it actually stops.
Use the benefit’s own end date, which is often the end of the month. Expect a window where someone is terminated with coverage still active - see Reading benefits.Result: The real loss-of-coverage date, per plan.
6

Reconcile on a schedule

Terminations are low-volume, so a lost webhook leaves no visible gap - and exhausted deliveries are never redelivered. Run this pass independently of events.
Compare terminal-status employees against those you’ve offboarded - see Recover a Missed Webhook Delivery.Result: A backstop that closes what events dropped.