Event Schema Versioning Policy
Last updated: 2026-02-18
This policy governs webhook event payload compatibility for enterprise consumers.
Versioning model
- Payload version field:
apiVersion - Current value source of truth:
src/lib/webhooks/events.ts(WEBHOOK_PAYLOAD_VERSION) - Format: date-based (
YYYY-MM-DD)
Compatibility guarantees
- Additive changes (new top-level optional fields) can be introduced without changing major integration behavior.
- Existing required fields are not removed inside the same
apiVersion. - Event type names are stable and treated as contract identifiers.
- Breaking payload changes require a new
apiVersionand coordinated rollout notice.
Where version appears
- Webhook payload body (
apiVersion) - AsyncAPI contract header fields (
x-webhook-version) - AsyncAPI payload schema constants
Consumer guidance
- Validate
x-webhook-versionand payloadapiVersiontogether. - Ignore unknown additive fields.
- Treat missing required fields as non-retryable schema errors.
- Pin contract snapshots from:
docs/integration-opportunities/contracts/asyncapi.webhooks.v1.jsondocs/integration-opportunities/contracts/openapi.enterprise.v1.json
Reference implementation:
sdks/typescript/src/webhooks.tsvalidateWebhookEnvelopeConsistencyparseWebhookPayloadWebhookSchemaValidationError(retryable = false)
Change management
- Update
WEBHOOK_PAYLOAD_VERSION. - Regenerate contracts (
npm run contracts:export). - Publish SDK/contract release notes.
- Keep old payload versions in replay logs for forensic traceability.