PushDeliveryProvider
Component Detail
Infrastructure
medium complexity
backend
0
Dependencies
0
Dependents
1
Entities
0
Integrations
Description
Infrastructure adapter that integrates with platform push notification gateways (FCM for Android, APNs for iOS) to deliver device-targeted alerts. It abstracts token registration, credential management, and platform-specific payload formatting so the rest of the system works against a single interface regardless of delivery channel.
push-delivery-provider
Sources & reasoning
Line 181 lists push notifications as a core always-available Mobile App capability, confirming MVP scope. Line 116 (HLF Phase 2) cites scenario-based push messages, but the base delivery infrastructure is required from launch. Line 298 confirms the inbox screen. Blueprint marks this [MVP].
-
docs/source/likeperson.md · line 181Push notifications and assignment tracking
-
docs/source/likeperson.md · line 116Scenariobaserte push-meldinger og kalendersynkronisering.
-
docs/source/likeperson.md · line 298Notification inbox
Responsibilities
- Register and store device push tokens mapped to user accounts
- Format notification payloads into FCM and APNs platform-specific structures
- Submit notifications to the appropriate gateway and capture delivery receipts
- Handle token refresh and invalidation when devices re-register or uninstall the app
- Report delivery failures back to PushNotificationService for retry logic
Interfaces
registerDeviceToken(userId: string, token: string, platform: 'android' | 'ios'): Promise<void>
unregisterDeviceToken(userId: string, token: string): Promise<void>
send(token: string, payload: PlatformPayload): Promise<DeliveryReceipt>
sendMulticast(tokens: string[], payload: PlatformPayload): Promise<DeliveryReceipt[]>
refreshToken(oldToken: string, newToken: string): Promise<void>