Introduction

Push notifications – give the possibility to send a message to a mobile application / browser, even when the application / website is disabled. This allows you to notify the user when an event has occurred.

Links (eg scanned by a QR code, it is best to open in a Chrome browser on a smartphone (preferably supports PWA notifications and applications))

RemoteMe.org

In RemoteMe it is possible to send a push message to mobile applications (article about mobile applications in RemoteMe) Push notification support is generated by default when the switch is on:

Turning it onĀ  creating files (the button is available only for android supported browsers here):

  • pushSupport.js – registers a button to show the status of notification, displays a message to enable push messages, and support push notifications when the application is enabled.
  • badge.png icons which appears in the smartphone in the notification bar (white and transparent)
  • adding libraries (firebase) in app.html
  • adding an installation script in app.html

After scanning the QR code, the application will ask if you want to enable push notifications, and a button will appear in the application in the bottom right corner

green color and the disappearing of the icon means that the installation was successful, a different color and message informs what went wrong. To repeat the installation process simply click on the bell icon, or refresh the application (in the smartphone, swiping the finger from top to bottom)

Sending Messages

By clicking on the burger menu page, where we want to send notifications:

Window appears

In order for the window to appear in this form, we must click Configure in the installation of the android application with the “Push notification support” option checked and install notifications in the browser or smartphone (opening the generated link and giving the consents mentioned earlier)

  1. The number of instances of applications to which notification will be sent
  2. The title of notification
  3. Notification body
  4. The icon on the notification bar in the smartphone
  5. Notification icon
  6. Picture of notification
  7. The code to be pasted from the sending device.
  8. We send a test notification.

After sending the notification on the smartphone icon will appear (if the application is not currently active, otherwise a small “snackbar” will be displayed)

and after expand:

(“sucess kid” is a picture selected in “6” in the previous window)

After clicking the notification, the application will open (unless it is currently open in the browser)

Similarly, we can send notifications to chrome on a PC, for this purpose, instead of scanning the path to the installation, copy it and paste it into the browser:

After sending the notification:

Note – that the notification will be delivered in this way, the domain app.remoteme.org can not be opened in any of the chrome tabs.

Managing instances of the application where notification is sent

It happens that we do not want to receive a notification anymore or we either revoke the application’s permission or remove it from remoteMe.

A window will appear, where we can delete the selected instance of the application:

Comments

  • In order for the notification to appear on the PC, in addition to opening the app.html and installation page, the domain app.remoteme.org can not be opened in any of the browser tabs where the installation was
  • In order for the notification to appear in the notification bar on the smartphone – the application can not be currently active
  • After some time of inactivity, smarpthone push messages will be delivered with a delay
  • On the RemoteMe page your application, where the application instance ID is in eRdDNzkuF78 format: APA91bH6LkgBJAE1QH [...] AQzTc5f this string of characters is not possible to extract any of your personal data.
  • The RemoteMe platform does not store or log the content of sent messages.