Customer events

View as Markdown

Six events fire on the customer resource. Each delivers the full customer object on data.object. Update events also include data.previous_attributes with the prior values of the changed fields.

EVENT TYPES
TypeFires when
customer.createdA customer is added — through the app, the API, or a CRM sync.
customer.updatedAny field on the customer changes. previous_attributes lists changed fields only.
customer.archivedA customer is archived. The object remains but stops appearing in the active list.
customer.health_score_droppedHealth score drops by 10 points or more between calculations.
customer.at_riskCustomer’s at-risk flag is set, either by Pi or by a CSM.
customer.churnedCustomer is marked churned.
PAYLOAD
customer.health_score_dropped
{
"id": "evt_2nQv...",
"type": "customer.health_score_dropped",
"data": {
"object": {
"id": "cus_2N...",
"display_id": 4218,
"name": "Acme Corp",
"health_score": 38,
"previous_health_score": 72,
"at_risk": true,
"churned": false,
"owner_email": "csm@yourdomain.com"
},
"previous_attributes": {
"health_score": 72,
"at_risk": false
}
}
}