Why use this plugin
- Push notifications: Enable push messaging workflows in your app.
- Event tracking: Send custom events to Braze for analytics and campaign logic.
- User targeting: Support segmentation and targeted messaging.
- Deep linking support: Open notification links directly in your app when deep linking is configured.
Prerequisites
- Access to the Braze plugin settings in Median App Studio (Native Plugins tab).
- Your Braze API keys and SDK endpoints for iOS and Android, from Settings → APIs and Identifiers in your Braze dashboard.
- Your Firebase Cloud Messaging Sender ID and
google-services.jsonfor Android (see Google Services). - If testing with the Median demo page, use
https://median.dev/braze/.
Implementation guide
Braze setup
Enable push notifications through Braze In-App Messaging as documented in the Braze push primer.App configuration
Enable the Braze plugin in the Native Plugins tab and fill in its settings.
App Studio – Braze plugin settings
Deep linking
Set up deep linking within your app, and notification links will automatically open directly into your app.JavaScript Bridge functions
Change user
Signs in an existing user or registers a new user in Braze context.Prompt for push notification permission
Prompts users to enable push notifications.Check push notification permission
Checks if push notification permission has been granted.Track custom events
Sends a custom event to Braze. Note: Custom events must be added in the Braze Dashboard.Testing checklist
Use this checklist to validate Braze integration:- Braze plugin configuration is set (including
active, platform API keys, and endpoint keys). -
median.braze.promptNotification()returns a permission result. -
median.braze.notificationEnabled()returns current permission state. -
median.braze.changeUser({ userId })is called for the active test user. -
median.braze.logCustomEvent()is called with a known event name. - Test notifications are sent to a test user from Braze (Test tab).
- Notification opens app when configured as Open App.
Troubleshooting
Test users are not appearing in Braze test send flow
Ensure your app callsmedian.braze.changeUser({ userId: "..." }) so the user is identified before sending test notifications.