[PAID] Personal Messaging

Released on : 19 Mar 2021

Last Updated on : 19 Mar 2021

Latest Version : 1.0.0

All Blocks
image image
Documentation
image

This event raises when any error occurred.

image

This event raises when your user has been registered in firebase.

image

This event raises when you fetch the onesignal player id of an user from database.

image

This event raises when you fetch the FCM token of an user from database.

image

This event raises when you send a notification and it response comes.

image

Initialize the Messaging with firebase URL. Your all user’s tokens will be stored in this given database URL. The same will be used for fetching the user tokens.

image

This block registers or stores an user’s token in the database. You can give both types of token to it but if you are not using both FCM and Onesignal then your can leave the other param empty. Where userId is unique id of your user that will be used to send notification. For ex, if you have a user with username then you can use its username to store tokens and later you can use the same username to send notifications to them.

image

Fetch the FCM token from user id that you have stored.

image

Fetch the Onesignal palyer id that you have stored.

image

Send the notification to the users with Onesignal API. You can use this block to send notifications to a list of users. Just give the user ids that you have used above to store the token then it will fetch them from the firebase and send them notification. You do not require REST API key for sending notification to specific player id but App ID is needed.

image

Send the notification to the user with FCM server. You will require server key for sending notifications.

How to Use

Let see a quick usage of the extension so you can understand how easily it is to set up this extension.

image

Your first step is to initialize the messaging with your firebase. And then you can register the user with player id or FCM token. You should use RegisterUser block only once in app or user when you have to update the tokens as it is useless to store the same thing again and again.

image

After the registeration success, you can test it by sending the notification to user ids. Extension will fetch the player id own from the firebase and send the notification own. That make the extension very usable cause it make our work very easy and short.

Firebase Structure

alt

Your all users will be listed down like this and you can fetch these tokens own or with extension.

Screenshots
image
Downloads

You can download this extension from AI2 Store.