Framework Recipes
Ready-made push setups for Swift (native iOS), Kotlin and Jetpack Compose (native Android), bare React Native, Expo and Flutter — the packages to install, getting the token, registering it, and showing Android pushes.
Every language and framework follows the same four steps — only "get the token" changes:
Get the platform token
- iOS: the APNs device token (hex string) from your app delegate.
- Android: the FCM registration token.
- Web: the browser's
PushSubscription— see Web Push.
Whichever library hands you the token is fine — APNs directly on iOS, FCM's SDK on Android, firebase_messaging on Flutter, expo-notifications' getDevicePushTokenAsync() in an Expo development build.
Register it with a stable deviceId
POST https://app.nativenotify.com/api/universal/device/register
Send the token in tokens.apnsToken (iOS) or tokens.fcmToken (Android) with platform ("ios" / "android") and a deviceId you persist across launches — the Quickstart has a minimal example per platform, and Device Registration is the full contract.
Save the app's push credentials
The FCM service account (Android) and Apple .p8 key (iOS) your sends go out with — Push Credentials.
Verify, then send
Prove one device with a test send, then send to an audience — every registered device (all), a device list, a subscriber list or a group. See Send Notifications.
Android shows nothing on its own:
Native Notify's Android pushes are FCM data messages (title, message, and body = your pushData as JSON). A native Kotlin, bare React Native or Flutter app must post the notification itself from its message handler — each recipe shows how. A test send reports accepted either way, because FCM accepted the message.
Recipes
| Framework | Token source | Recipe |
|---|---|---|
| Swift (native iOS) | UIApplicationDelegate + APNs | Swift recipe |
| Kotlin (native Android) | FirebaseMessaging | Kotlin recipe |
| Jetpack Compose (Android) | FirebaseMessaging + rememberLauncherForActivityResult | Jetpack Compose recipe |
| Bare React Native | @react-native-firebase/messaging / APNs delegate | Bare React Native recipe |
| Expo (React Native) | expo-notifications (a development build) | Expo recipe |
| Flutter | firebase_messaging | Flutter recipe |
| Web (browsers) | PushManager.subscribe() | Web Push recipe |
Anything not listed — .NET, Unity, a KMP app, a backend that holds device tokens — registers with the same JSON contract. Start from the Quickstart or Device Registration.