Kaiten
Core Concepts

Events & Webhooks

The transactional outbox pattern, event catalog, and Svix-powered webhook delivery.

Events & Webhooks

Kaiten uses an event-driven architecture to notify external systems of changes. Every mutation (create, update, delete) emits a domain event delivered via webhooks.

How It Works

Go API Handler
  │  Domain write + INSERT INTO outbox_events
  │  (same Postgres transaction)

Postgres WAL
  │  Debezium CDC (captures outbox_events)

RabbitMQ (exchange: kaiten.events)
  │  Fanout → queue

Dapr Sidecar (pubsub)
  │  HTTP POST /events

Webhooks Worker
  │  Parses CDC envelope → calls Svix

Svix → Your webhook endpoints

Transactional Outbox Pattern

The key guarantee is at-least-once delivery: domain writes and event inserts happen in the same Postgres transaction. If the write succeeds, the event is guaranteed to be captured by Debezium CDC.

No Go poller is used — the pipeline is entirely CDC-driven.

Event Shape

{
  "name": "CUSTOMER_CREATION",
  "type": "com.kaiten.customer.v1.created",
  "data": { "...domain payload..." },
  "headers": { "...optional..." }
}
FieldDescription
nameHuman-readable event name (SCREAMING_SNAKE)
typeCloudEvents / Svix type string
dataDomain-specific payload

Event Catalog Summary

Kaiten emits 27 events across 7 domains:

DomainCountEvents
Customer3Creation, Update, Deletion
Entitlement3Creation, Update, Deletion
License6CRUD + Entitlement Assignment/Unassignment/Update
Instance6CRUD + Deployment, Migration, Usage Reached
Deployment Zone4CRUD + Release Deployment
Release2Creation, Deletion
Feature Flag3Creation, Update, Deletion

See the full event catalog for complete details.

Svix Delivery

Svix handles webhook delivery with:

  • Automatic retries with exponential backoff
  • Delivery history and status tracking
  • Signature verification for endpoint security
  • One Svix "app" per Kaiten organization

See It in the Console

The Console lets you manage webhook endpoints visually — register URLs, view delivery history, and inspect event payloads.

On this page