FCM Push Notifications Not Working

Ronald5 years ago

Greetings

I recently updated to the latest version of Traccar. I have also built my own android app using the official source code and integrated it with Firebase.
If i run push notifications from the Firebase console, they are being delivered to the phone with no problem but i am unable to see any push notifications that i trigger from Traccar (web and mail notifications are displaying okay)

I have added the following to my config line and restarted the server to no avail.

<entry key='notificator.types'>web,mail,firebase</entry>
<entry key='notificator.firebase.key'>FIREBASE_SERVER_KEY</entry>

If i login using the app, no tokens are created in the user attributes as should be.

Anyone who has encountered such an issue? what are the possible fixes so i can try them out?

Anton Tananaev5 years ago

You should debug the mobile app and see why tokens are not created.

Ronald5 years ago

Hello Anton

Thanks. I managed to get it working using the google release.
Now the issue is that the icon that shows on the notifications bar is a black Traccar logo.
I have updated the app res with my correctly sized icons. My icon shows up both on the Homepage and when i pull down the notifications tray to see the notification.
However the black Traccar logo shows up when the notification is triggered. In more dark themes its very much invisible.
Can you direct me to the file to edit or image to replace for this one.
I have attached a sample below for reference
https://imgur.com/a/QH3Tsti

Thanks

Ronald5 years ago

I have also managed to tweak the colors. My last questions is, how can i make Traccar push notifications stick around until they are cleared by the user?
They seem to be auto clearing after a few minutes unlike other apps