Push notifications are available in GrandNode from version 4.20. By writing push notifications, I mean small, graphical pop-ups that show up in the bottom right corner of the screen, regardless of whether the customer is currently in your store. Usually it contains the most important information about your store. For example you can notify your customers about new products, new promotion. It all depends on your marketing strategy.
Below you will find a short guide, coming from our documentation about push notifications configuration. If you will have any questions, feel free to ask questions on our community board.
Fill in your project name and region.
2. Now that our project is created we are ready to configure push notifications in GrandNode. Navigate to settings in your firebase console.
Go to „cloud messaging” tab and copy Server key.
Paste it into „Private Api Key” in push notifications configuration. To do that go to Admin Panel -> Configuration -> Settings -> Push notifications settings
Go back to firebase settings -> General tab and press „Add Firebase to your web app”.
Copy settings from config json into configuration. „apiKey” into „Public Api Key” etc. It should look like this:
Depending on your account „storageBucket” might be empty, but it seems to be optional so don’t worry about it. After pressing „Save” in our plugins’ configuration page everything is ready, but let me write few words about those keys and other settings.
„Private Api Key” shouldn’t be shown to anyone, as it’s the key that will allow you to send notifications.
„Public Api Key” and all other fields we just filled are public and it isn’t dangerous to show them to the world. They will be visible on your page and in some scripts, because firebase needs to know that this page is ready to receive notifications from you.
„Widget zone” field indicates on which page registration for push notifications(aka showing the „Allow notifications” popup) should occur. We advise to leave it to „home_page_top” to avoid performance issues, but feel free to test it on your own, for example „footer” will add script to each page that has footer in it etc.
„Allow guest to register for notifications” is pretty self-explanatory. Disable this setting if you wan’t only registered users to be able to subscribe to your notifications.
3. Everything is set and ready to go. With default settings after someone visists your homepage you should be able to see him in „Receivers” tab in plugin configuration.
If there is at least one customer that subscribed to your push notficiations you are ready to send them. Go to „Send” tab, fill in the form and press „Send message” to do that. Any erros will get logged into system log. Errors are inevitable, because there always will be some users with old browser cache or that are using Internet Explorer from ancient times. History of sent messages is in „Messages” tab.
[Disclaimer for developers] If you have purchased source codes, you are able to send push
notifications programatically, by calling SendPushNotification(…) form PushNotificationsService.
Few words about receiving notifications:
Every browser is different, but usually there will be two scenarios – either customer is currently on your website or not.
-If he is, he must have page with registration script(so with the widget zone from settings) in it open. Clicking on notification will result in no action, even if „Click Url” in „Send” form was filled.
-If he isn’t on your store, he will receive push notification. Clicking on it will result in opening specified url(depending on you filling it earlier). If his browser isn’t open at the moment of sending notification he should receive it when he opens it(again – different browsers might give different results. When tested Chrome and Firefox opened old notifications even if PC was shut down at the moment of sending notification, Opera not).