Send Push Notification dont work

Nabil5 years ago

Hi,
I can send push notifications from the firebase platform (FCM) to my phone without any problem.

I have entered all the necessary information on the configuration file "traccar.xml", but it does not work when I test either by the traccar web platform or TRACCAR MANAGER application.

here is what I did:

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

why does not it work? , who have already work on this project to help me please?

thank you in advance

Anton Tananaev5 years ago

Have you successfully tested firebase with Traccar Manager? If not, what did you use?

What kind of push notifications are you expecting in web platform? Push notifications are only for Traccar Manager app.

Nabil5 years ago

Hi Anton,
1-Have you successfully tested firebase with Traccar Manager? If not, what did you use?
I tested it on a mobile application that I devolved on Android Studio and installed on my mobile phone

2- What kind of push notifications are you expecting in web platform? Push notifications are only for Traccar Manager app:
just when I click on the icon "Send Test Notification" I do not receive the notification on the application that I have devoloped

Anton Tananaev5 years ago

Check user attributes to see if you have a correct token there. If you do, there must be configuration issue with your setup.

techguru5 years ago

Anton just a Question how to check user attribute, i have same issue and i have checked from DB user attribute table its empty

Anton Tananaev5 years ago

From the UI you just click "attributes" button from the user account settings. If it's empty, it means that your Traccar Manager app hasn't registered with your server properly. In this case you obviously won't be able receive anything because server doesn't know your device token.

Nabil5 years ago

Many thank
I can solve the problem and here is what I did:
1- download the source code of TRACCAR MANAGER
2- modify it by linking it to our firebase platform/ Project
3- Compile and build a new APK file( NabilTraccarManager.apk )
4-install it on my smart phone
5- do a test

Result OK

NB: The token is automatically installed on the attributes of the user which allows us to receive a notification for each event

techguru5 years ago

@Nabil

Can you share any screenshot where i can see token in attributes?

Nabil5 years ago
techguru5 years ago

Hi Nabil,

Thanks for Detail screenshot i checked Notification token is missing

Nabil5 years ago

Hi,
this token is created automatically By TRACAR SERVER during the first connection of My TRACCAR MANAGER .
It's specific to my device

Once your TRACAR MANAGER connects to your TRACAR server, you will see that it is automatically added to your user attributes .
this "Notificationtoken" will be specific to your mobile phone

Josue4 years ago

@Nabil public again the pics, plis

Rock4 years ago

Hi! A server can be configured to send notifications to several TRACCAR-MANAGER, each one with a different user, with a different notificatoken ????

Anton Tananaev4 years ago

That's how it works it works by default, obviously. Each user receives their own notifications.

Rock4 years ago

OH, so i have to see configuration for notification! thx for the great work!!!