Mobile Notifications
Purpose
Plan notifications: choose the provider, request permissions, register tokens, handle foreground/background delivery, and route taps (often via deep links).
When to Use
- When the app sends push or schedules local notifications.
- Not on Expo Go alone (needs a dev build or CLI).
Inputs
- Notification requirements (push/local, data payloads).
- Provider (Expo push / FCM / APNs); runtime + build model.
Discovery Questions
- Push, local, or both? What payloads/data?
- Which provider (Expo push / FCM / APNs)?
- How are permissions requested and tokens registered/synced?
- What happens on tap (deep-link routing)?
Responsibilities
- Choose the provider and confirm native support (dev build/CLI).
- Handle permissions and token registration/sync to the backend.
- Handle foreground/background/tap delivery.
- Route taps via deep linking (
mobile-deep-linking, mobile-navigation).
Required Workflow
- Confirm requirements + provider + native build.
- Request permissions; register/sync tokens.
- Handle foreground/background/tap.
- Wire tap to deep-link routing.
- Record the notification plan.
Decision Rules
- Notifications need native support — plan a dev build (Expo) or CLI, not Expo Go.
- Sync device tokens to the backend; handle token refresh.
- Request permission at a contextual moment, not blindly on launch.
- Tap handling routes through the navigation/deep-link layer.
Rules
- Respect OS permission models and user choice.
- No secrets in notification payloads (
../../security-review).
- Coordinate routing with deep-linking/navigation.
Anti-Patterns
- Assuming Expo Go supports push.
- Requesting permission with no context.
- Not syncing/refreshing tokens.
- Ad-hoc tap handling bypassing navigation.
Validation Checklist
Definition of Done
A recorded notification plan: provider with native support, permissions and token sync, delivery handling across states, and tap-to-deep-link routing — with no sensitive payload data.
Related Skills
mobile-deep-linking, mobile-navigation, mobile-background-tasks, mobile-native-modules, mobile-builds, ../../security-review
Related Knowledge
../../../knowledge/ (messaging requirements).
Related References
../../../references/mobile/notifications/ when populated.
Context Loading Guidance
- Requires: notification requirements, provider, runtime/build model.
- Does not require: unrelated screens, the full mobile skill set, unrelated references.
- May load:
mobile-deep-linking, mobile-navigation, mobile-background-tasks.
- Stop when: the notification plan is recorded.
Token Efficiency Guidance
Plan provider + handling; delegate routing to deep-linking and builds to mobile-builds.
1---2name: mobile-notifications3description: Use to plan push/local notifications — provider (Expo push / FCM / APNs), permissions, token registration, handling foreground/background, and deep-link routing from taps. Requires native support (dev build or CLI).4---56# Mobile Notifications78## Purpose910Plan notifications: choose the provider, request permissions, register tokens, handle foreground/background delivery, and route taps (often via deep links).1112## When to Use1314- When the app sends push or schedules local notifications.15- Not on Expo Go alone (needs a dev build or CLI).1617## Inputs1819- Notification requirements (push/local, data payloads).20- Provider (Expo push / FCM / APNs); runtime + build model.2122## Discovery Questions2324- Push, local, or both? What payloads/data?25- Which provider (Expo push / FCM / APNs)?26- How are permissions requested and tokens registered/synced?27- What happens on tap (deep-link routing)?2829## Responsibilities3031- Choose the **provider** and confirm native support (dev build/CLI).32- Handle **permissions** and **token registration/sync** to the backend.33- Handle **foreground/background/tap** delivery.34- Route taps via **deep linking** (`mobile-deep-linking`, `mobile-navigation`).3536## Required Workflow37381. Confirm requirements + provider + native build.392. Request permissions; register/sync tokens.403. Handle foreground/background/tap.414. Wire tap to deep-link routing.425. Record the notification plan.4344## Decision Rules4546- Notifications need native support — plan a dev build (Expo) or CLI, not Expo Go.47- Sync device tokens to the backend; handle token refresh.48- Request permission at a contextual moment, not blindly on launch.49- Tap handling routes through the navigation/deep-link layer.5051## Rules5253- Respect OS permission models and user choice.54- No secrets in notification payloads (`../../security-review`).55- Coordinate routing with deep-linking/navigation.5657## Anti-Patterns5859- Assuming Expo Go supports push.60- Requesting permission with no context.61- Not syncing/refreshing tokens.62- Ad-hoc tap handling bypassing navigation.6364## Validation Checklist6566- [ ] Provider chosen + native support confirmed.67- [ ] Permissions + token registration handled.68- [ ] Foreground/background/tap handled.69- [ ] Tap to deep-link routing wired.70- [ ] No sensitive data in payloads.7172## Definition of Done7374A recorded notification plan: provider with native support, permissions and token sync, delivery handling across states, and tap-to-deep-link routing — with no sensitive payload data.7576## Related Skills7778`mobile-deep-linking`, `mobile-navigation`, `mobile-background-tasks`, `mobile-native-modules`, `mobile-builds`, `../../security-review`7980## Related Knowledge8182`../../../knowledge/` (messaging requirements).8384## Related References8586`../../../references/mobile/notifications/` when populated.8788## Context Loading Guidance8990- **Requires:** notification requirements, provider, runtime/build model.91- **Does not require:** unrelated screens, the full mobile skill set, unrelated references.92- **May load:** `mobile-deep-linking`, `mobile-navigation`, `mobile-background-tasks`.93- **Stop when:** the notification plan is recorded.9495## Token Efficiency Guidance9697Plan provider + handling; delegate routing to deep-linking and builds to mobile-builds.