Platform Module

Notifications & Real-Time Alerts

Multi-channel notification engine — email, in-app, and real-time WebSocket — triggered automatically by 24 platform events across 5 domains. Every notification respects user preferences and tenant branding.

Delivery Channels

Three channels, one engine

Platform events trigger notifications across email, in-app, and WebSocket simultaneously. User preferences control which channels deliver each event type.

Kafka Events24 event types5 domains
Email

Via Resend API with branded HTML templates

Order confirmations, invoices, credentials delivery

In-App

Stored in database, displayed in dashboard

Unread badges, notification history, real-time feed

WebSocket

Real-time push via Socket.io

Live provisioning updates, instant alerts, admin dashboard

Event Coverage

24 events, 5 domains

Every significant platform action triggers targeted notifications. Customer and admin receive different channels — customers get confirmations, admins get operational alerts.

Order5
order.created
order.fulfilled
order.failed
order.cancelled
order.service-delivered
Provisioning6
provisioning.started
provisioning.step-completed
provisioning.completed
provisioning.failed
provisioning.rolled-back
provisioning.service-suspended
Billing5
billing.invoice-generated
billing.payment-received
billing.subscription-past-due
billing.refund-completed
billing.subscription-cancelled
Support5
support.ticket-created
support.comment-added
support.ticket-resolved
support.ticket-assigned
support.ticket-closed
Identity1
identity.user-created
Email Templates

18 Handlebars templates

Professional HTML email templates with full customization. Handlebars syntax for conditionals, loops, and variable interpolation. Live preview, test sending, versioning, and in-memory caching with auto-clear on update.

Live PreviewRender template in real-time before deploying
Test SendingSend test emails to any address with sample data
VersioningTrack version numbers, activate/deactivate templates
Compiled CacheTemplates cached in memory, auto-cleared on update
Service Delivery Emailkey template

The most important notification — when infrastructure is ready:

IP address and hostname
SSH connection command
HTTP/HTTPS endpoints
Security recommendations
Link to customer dashboard
White-Label Branding

Per-tenant email customization injected into every template as Handlebars variables. One configuration covers all 18 templates — update once, every email reflects the change.

Logo URLCompany logo in email header
Primary ColorButtons, links, accents
Secondary ColorSecondary text, borders
Company NameHeader and footer branding
Footer TextCustom footer appended to all emails
Reply-To AddressOverride reply address for outbound
Admin Alerts

Admins receive separate notifications for new orders with item breakdown, provisioning progress (start, step completion, failures), and rollback events with affected resource lists.

Real-Time & Preferences

WebSocket gateway & user control

Customer WebSocket
JWT-authenticated (same as REST API)
Per-user rooms — correct browser session
Multi-tab support — all tabs receive updates
Unread count synced across sessions
Admin Dashboard
Provisioning updates broadcast to all admins
Live progress: "Step 2/4: Configuring..."
Instant failure alerts with error details
Real-time order and billing notifications
User Preferences
Per-event granularity — control each event type
Per-channel toggle — email, in-app independently
Default: all enabled, auto-created on first access
Upsert — update creates preference if missing
WebSocket Connection Lifecycle
ConnectJWT VerifyJoin user:{id} roomReceive eventsDisconnectCleanup
Reliability & Delivery

Resilient by design

Circuit Breaker

5 failures open the circuit for 60 seconds — prevents cascading email API failures

Bulkhead

Max 5 concurrent email sends, 20 queued — isolates notification load from platform

Kafka Retry

Exponential backoff on processing failures — no events lost, guaranteed delivery

Delivery Tracking

Every notification records Pending → Sent → Delivered → Failed with timestamps

Delivery Status
Pending
Sent
Delivered
Failed

Never miss a platform event

Multi-channel notifications with white-label branding, user preferences, and real-time WebSocket delivery — fully automated.

FAQ

Common Questions

Yes. Every user controls which notifications they receive per event type with per-channel granularity. Disable email for billing events but keep in-app, or vice versa. Defaults are all-enabled, and preferences auto-create on first access.

One branding configuration covers all 18 email templates. Logo, colors, company name, and footer text are injected as Handlebars variables. Update branding once and every outbound email reflects the change immediately.

The circuit breaker opens after 5 consecutive failures, pausing email sends for 60 seconds. Meanwhile, in-app notifications and WebSocket events continue unaffected. Failed emails are retried via Kafka consumer with exponential backoff.

Each tab connects independently and joins the same user room. All connected tabs receive updates simultaneously. Unread counts sync across sessions in real-time. On disconnect, the connection is cleaned up automatically.