Not sure what you mean. There's no connection between our website user accounts and your Traccar server user accounts.
If I understand the original post correctly, in order to enable push notifications the user notification token from the traccar manager app must be entered in traccar.xml. That limits the notifications to that specific user. is there a way to enable notifications for other users who have the manager app?
You shouldn't read the original post. You don't need to enter user notification token in the config file. That makes absolutely no sense. I would recommend you to read the official documentation instead of reading comments from other people who probably don't understand what they're talking about.
@erstenor The answer to my question above is "no". The API key (that you can find in your accout on the Traccar website) must be entered in traccar.xml in order to make push notifications working. The user notification token is generated automatically. You don't need to care about it.
@Anton and @Daniel thanks for the quick replies. Sorry if my comment makes absolutely no sense. I am following the documentation here:
"Push Configuration"
https://www.traccar.org/notifications/#:~:text=password%27%3Epassword%3C/entry%3E-,Push%20Configuration,-Push%20ntifications%20are
Is that not the correct documentation?
I'm running traccar on my own server (fleet.myselfhosted.server). The token from my traccar.com user account doesn't work with my self-hosted server config. However, when I input the Notification token from my user account settings on my server the notifications work. However, that's limited to sending notifications to my user. Forgive me if I'm missing something in the documentation but I'd like other users who are running the traccar manager app connected to our self-hosted server to receive geofence notifications.
The notifications are user specific. Every user must set up his own notifications. As admin you can switch to another user account and manage settings for that account (via settings -> users).
erstenor what you said makes absolutely no sense. Configuration fine needs a server side key. It will never work if you use user device token as a key. You're definitely missing something.
@Daniel, does that mean each user needs a token entered in traccar.xml? If yes, does that require a new <entry key... >
line?
@Anton, I'm not using a device token. I'm entering the token from Settings-Account-Attributes, Notification Token. The following is what I've added to traccar.xml:<entry key='notificator.types'>traccar,web,mail</entry>
<entry key='notificator.traccar.key'>MY_USER_NOTIFICATION_TOKEN></entry>
Using the push notification key from my traccar forums account seems to have no effect (presumably because my instance is self-hosted and not using the traccar.com server).
"Settings-Account-Attributes, Notification Token" is the device token. What you're showing as the config will never work.
No, it doesn’t. As I wrote: „The API key (that you can find in your accout on the Traccar website) must be entered in traccar.xml in order to make push notifications working.“ That should make push notifications working for your self-hosted instance.
Then (after restart of Traccar), log into the platform and set up your notifications (settings -> notifications). These notifications are user specific. Each user has to set up his own notifications.
Using the push notification key from my traccar forums account seems to have no effect (presumably because my instance is self-hosted and not using the traccar.com server).
@Anton, please disregard. I was a dummy and didn't properly escape out the <entry...>
tag. The push notification token from my traccar forums account works as expected and sends a push notification to the traccar manager app on my phone.
I'm still trying to figure out how to do the same for multiple users. Create another <entry key...>
line containing the token for additional registered users?
You only need one token. It will work for all users.
You only need one token. It will work for all users.
Thank you. I will have other users test.
Do push notifications only work for the user who own the account on traccar.org where the API key is from? Or should they work for all users on the platform? (I don’t get them working for another user.)