Events & suppressions

Backend lifecycle catalog

Events are grouped by stage in @thl/events:

  • Site and lead capture (page_viewed, lead_captured, …)
  • Intake and checkout
  • Clinical review and labs
  • Orders and fulfilment
  • Subscription and billing
  • Feedback and referrals

Launch events (V1 default triggers)

Fifteen names are enabled for initial journeys:

page_viewed, lead_captured, intake_started, checkout_started, prescription_approved, prescription_denied, order_placed, order_shipped, order_delivered, order_refunded, renewal_upcoming, renewal_charged, payment_failed, subscription_paused, subscription_cancelled

Platform message events

Email and SMS pipelines emit delivery events (email_sent, email_delivered, email_opened, email_clicked, email_bounced, unsubscribes, and related). These power analytics and suppressions.

Suppressions

Hard bounces, complaints, and global unsubscribes block sends at enqueue time. Suppression rows store reason codes, not message content.

Parsing boundary

Unknown JSON fields drop at ingestion. Fields such as ssn, date_of_birth, or free-text intake answers never persist if they are not in the schema.