Event Catalog and Triggering Strategy
This is the most important page for long-term stability.Catalog design rules
- Event names are stable contracts.
- Payloads evolve backward-compatibly by default.
- Breaking payload changes require explicit versioned event name.
- Event ownership is domain-based (billing, projects, identity).
What your codebase already supports
Your backend webhook API includes event catalogs and app catalog assignment (/webhooks/event-catalogs/* and /webhooks/apps/{app_slug}/catalog).
This lets you manage event definitions centrally and reuse across apps.
Trigger timing rules
Trigger only after business state is committed. Bad:- Emitting event before DB commit and then rolling back.
- Commit domain mutation first.
- Emit event from post-commit workflow.
Payload design
Always include:- Stable primary identifiers (
id,external_idwhen relevant). - Event timestamp in UTC RFC3339.
- Minimal required context for consumer decisions.
- No secrets or privileged internal fields.
Suggested event naming
invoice.createdinvoice.paidinvoice.failedsubscription.cancelledproject.export.completed
Change management checklist
- Diff payload schema in PR.
- Notify consumers for additions and deprecations.
- Keep deprecated fields during migration window.
- Remove only after announced end date.
Related docs
- React Router
useWebhookEvents - React Router
useWebhookEndpoints - React Router
useWebhookDeliveries - React Router
useWebhookAppSession - Webhooks Backend API Reference
Go-live checklist
- Event catalog and naming policy are frozen for current release.
- Endpoint test flow is working for pilot customers.
- Replay workflow is documented for support.
- Signature verification docs are published for customers.
- Alerts for endpoint failures and deactivations are active.
