Notification Preferences Service
Component Detail
Service Layer
medium complexity
backend
0
Dependencies
0
Dependents
0
Entities
0
Integrations
Description
Backend service that manages per-user notification preferences. Provides read and write APIs for the settings screen and is consulted by the scenario dispatcher before delivering any notification.
notification-preferences-service
Sources & reasoning
Notification preferences are implied by the WCAG 2.2 AA mandate (line 16) and the accessibility touch-target requirement (line 21), and required to deliver the per-scenario channel choices in notification-scenarios. As baseline privacy/UX hygiene it belongs in MVP alongside push.
-
docs/source/likeperson.md · line 16Appen SKAL oppfylle WCAG 2.2 nivå AA som minimumskrav for alle skjermer og interaksjoner - fra dag én, for alle organisasjoner.
-
docs/source/likeperson.md · line 21Touch targets: Minimum 24x24 CSS-piksler for alle interaktive elementer (WCAG 2.2 target size).
Responsibilities
- Retrieve a user's notification preferences with role and module filtering applied
- Persist updates to categories, channels and quiet-hours
- Evaluate whether a given scenario should be delivered to a user on a given channel
- Enforce defaults for new users and newly enabled modules
- Validate preference payloads against allowed categories and channels
Interfaces
getPreferences(userId): NotificationPreferences
updatePreferences(userId, prefs): NotificationPreferences
shouldDeliver(userId, scenarioId, channel, timestamp): boolean
listAvailableCategories(userId): Category[]