EdgeInteract
Notification Component
The NotificationComponent renders a read-only message with an Acknowledge button. Unlike the other interaction types, there is no decision to make — the user simply confirms they saw the message. This creates a compliance-grade acknowledgement record.
Live Mockup (Error Severity)
Security Policy Update
Effective 2026-06-01, all API tokens will require 2FA. Tokens created before this date will be invalidated. Please rotate your tokens before the deadline to avoid service interruption.
Notification Payload Schema
interface NotificationPayload {
/** The notification message body */
message: string;
/** Severity affects icon and border color */
severity?: 'info' | 'warning' | 'error'; // default: 'info'
/** Optional URL to a full policy document or resource */
documentUrl?: string;
/** Label for the acknowledge button (default: "Acknowledge") */
acknowledgeLabel?: string;
}
Response Schema
// Outcome: "acknowledged" — always
// No data required
respond("acknowledged")
Severity Variants
| Severity | Icon | Border Color | Use Case |
|---|---|---|---|
info | info circle | Blue | Informational announcements, release notes |
warning | triangle warning | Yellow | Upcoming changes, deprecations |
error | exclamation circle | Red | Critical security alerts, mandatory policy updates |
Compliance Use Case
The notification type is specifically designed for compliance scenarios where you need to prove that a user received and acknowledged a specific message. The EdgeInteract audit log records:
- Which user received the notification (
targetUserId) - The exact notification content (
payload.message) - When the notification was sent (
InteractionRequest.PublishedAt) - When the user acknowledged (
InteractionResponse.Timestamp) - The user's session ID and IP at acknowledgement time
Server-Side Usage
// Send a mandatory policy acknowledgement to all employees
foreach (var employee in await _hr.GetAllActiveEmployeesAsync(ct))
{
await _publisher.PublishAndWaitAsync(new InteractionRequest {
Type = InteractionTypes.Notification,
TargetUserId = employee.UserId,
Title = "Security Policy Update",
Payload = new NotificationPayload {
Message = "Effective 2026-06-01, all API tokens require 2FA...",
Severity = "error",
DocumentUrl = "https://policies.bizfirstai.com/token-policy-2026",
AcknowledgeLabel = "I Understand"
},
TimeoutMs = 604_800_000 // 7 days
}, ct);
}