Push Notifications
Audience:
Low-code EngineersSkill Prerequisites:
Actions,Tokens,Connectors,Firebase or Pushwoosh account
The Push Notifications add-on sends push notifications to mobile apps and browsers through Firebase Cloud Messaging (FCM) or Pushwoosh. It adds actions that build and send the notifications, an action that subscribes devices to Firebase topics, and a PushWoosh connector type with actions to manage it.
This add-on is the DnnSharp.PushNotifications package. It's installed separately and needs the PUSHN feature in your license. If it isn't licensed, the actions fail with a "not licensed" error. If you don't see the Push Notifications action group, the add-on isn't installed.
Choosing an action
| Action | What it does | Use it to |
|---|---|---|
| Firebase - Send push notification | Sends a notification through Firebase to a topic, a device or a list of up to 100 devices. | Notify the users of your mobile app or web app. |
| Firebase - Create Android message | Builds the Android settings of a notification as JSON, in a token. | Set the priority, icon, sound or click action of the Android notification. |
| Firebase - Create iOS message | Builds the iOS (APNs) settings of a notification as JSON, in a token. | Set the badge, sound, subtitle or category of the iOS notification. |
| Firebase - Create WebPush message | Builds the browser (WebPush) settings of a notification as JSON, in a token. | Set the icon, image, buttons or behavior of the browser notification. |
| Firebase - Assign/Unassign to Topic | Subscribes devices to a Firebase topic, or unsubscribes them. | Group devices, for example by interest, so you can notify them all at once. |
| Create PushWoosh Notification | Sends a notification through Pushwoosh, now or at a set date, to all devices or to selected users or devices. | Notify the users of an app that uses Pushwoosh. |
| Add PushWoosh Connector | Adds a PushWoosh connector with an API access token to a group. | Save a customer's Pushwoosh account from a setup form. |
| Update PushWoosh Connector | Replaces the title and API access token of a PushWoosh connector. | Save a new Pushwoosh access token. |
Firebase
Credentials
The Firebase actions don't use a connector. They use a Firebase service account key file on the server:
- In the Firebase console, open Project settings > Service accounts and generate a private key. Firebase downloads it as a JSON file.
- Save the file on the web server, in a folder that isn't served to browsers.
- In the
appSettingssection ofweb.config, add a key whose value is the full path of the file, for example<add key="FirebaseCredentials" value="C:\Keys\my-app-firebase.json" />. - Enter the key's name,
FirebaseCredentialsin this example, in the Credential Key parameter of Firebase - Send push notification and Firebase - Assign/Unassign to Topic.
If the key isn't in web.config, or its file doesn't exist, the action fails with an error that says so. The file is loaded the first time a key is used. If you replace the file later, restart the site.
Building and sending a notification
The Create message actions don't send anything. Each one builds the settings for one platform and saves them as JSON in its Output Token. Then Firebase - Send push notification sends the notification:
- Optionally, run Firebase - Create Android message, Create iOS message or Create WebPush message with an Output Token, for example
AndroidJson. - Run Firebase - Send push notification, and pass the tokens into Android Specific Notification Json, iOS Specific Notification Json and WebPush Specific Notification Json, for example
[AndroidJson].
The Message Title and Message Body of the Send action are used on every platform. A title or body set in a Create message action replaces them on that platform. A Create message action without an Output Token does nothing.
Every Firebase action except Assign/Unassign has Data, the custom key/value pairs sent to the app. Enter them in the grid, or give the name of a list whose items have key and value fields.
The device registration tokens come from the Firebase SDK in your app. Your app has to send them to your site, where you can save them, for example with the user. To notify many devices at once, subscribe them to a topic with Firebase - Assign/Unassign to Topic and send to the topic.
In 1.28, Firebase - Send push notification doesn't report send errors. It logs them and carries on. If notifications don't arrive, check the site's log. See Considerations.
Pushwoosh
Create PushWoosh Notification sends one notification through the Pushwoosh API. It reads your Pushwoosh API access token from a PushWoosh connector:
- Create the connector on the Connectors page, or from a setup form or workflow with Add PushWoosh Connector.
- Save a new access token with Update PushWoosh Connector.
- The PushWoosh connector can't be checked with Test Connector, so send a test notification after you create it.
For other connector actions, see Connectors. For text messages, see Twilio.
Revised 10/03/2026