v402 — Notification Scheduled Digest Planning and Guarded Trigger Rules
Status: Build history record
Product UI impact: Workspace Settings > Notifications only
Prisma schema impact: none
Summary
v402 reviewed v401 and continued the notification delivery track. It adds scheduled digest planning and guarded trigger checks while preserving the placement rule introduced after v390.
Product changes
- Added scheduled digest plan data to GET /api/app-notifications/email-digest.
- Added CHECK_TRIGGERS support to POST /api/app-notifications/email-digest.
- Added guarded trigger evaluation for urgent alerts, overdue or late work, due-today checks, and daily team digests.
- Added duplicate-send guards for empty digests, repeated pending attempts, cooldowns, and repeated daily team digests.
- Added an automation lock controlled by DISPATCH_SPOT_NOTIFICATION_AUTO_DIGEST_ENABLED=true.
- Default behavior remains approval-first unless automation is explicitly enabled.
- Reused existing OutboundEmailLog records. No Prisma change was required.
Placement rule
/notifications remains alert/action-only. Digest planning, digest history, trigger checks, and readiness wording remain inside Workspace Settings > Notifications. Provider setup remains in Workspace Integrations.
Guarded automation rule
Automatic digest sending must remain locked unless explicitly enabled at the platform/deployment level. Even when enabled, sends must pass readiness, item selection, duplicate-send, and cooldown checks before sending.