feat(notifications): persistent read cursor + delivery history

notification_cursors table stores one read-cursor per user per tenant;
GET /v1/activity returns unreadCount + readAt, POST /v1/activity/read
persists the cursor. Reminder dispatches now append reminder.sent /
reminder.failed system events so delivery history reaches the feed.

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
Tomas DvorakandDevin committed 2026-09-18 16:55:21 +02:00
1 parent 76e45d4178
commit 2464aa45fa
14 files changed
+332 -8

No files matched your search

+3 -1
View File
@@ -553,7 +553,9 @@ type ActivityEvent struct {
}
type ActivityFeedResponse struct {
Events []ActivityEvent `json:"events"`
Events []ActivityEvent `json:"events"`
UnreadCount int `json:"unreadCount"`
ReadAt *time.Time `json:"readAt,omitempty"`
}
// StaffMetric aggregates appointment workload for one staff member over a