Update:
I saw that the notificationTokens are on attributes on the user, but when i make the same call with Postman in PUT mode.
{
"attributes": {
"notificationTokens": "example"
}
}
I just get
Cannot invoke "org.traccar.model.User.getAdministrator()" because "before" is null - NullPointerException (PermissionsService: 179 < BaseObjectResource: 95 < ... < OverrideFilter: 49 < ...)
You have to send the whole model. We don't support any patch API.
{"id":1,"attributes":{"activeMapStyles":"custom","notificationTokens":""},"name":"XXXXXXXXXXXXX","login":null,"email":"adminmail@gmail.com"
,"phone":null,"readonly":false,"administrator":true,"map":null,"latitude":0.0,"longitude":0.0,"zoom":0,"twelveHourFormat":false,
"coordinateFormat":null,"disabled":false,"expirationTime":null,"deviceLimit":-1,
"userLimit":0,"deviceReadonly":false,"limitCommands":false,"disableReports":false,"fixedEmail":false,
"poiLayer":null,"totpKey":null,"temporary":false,"password":null}
That's what i got on all the model when i navigate to https://www.mytraccarurl.com/api/users/1
Hello, i want to update the notificationsToken by my generated token on my app on IONIC, but i try to make the call to the API from Postman and the response is:
The authorization is Basic Auth with my credentials, the URL is
https://www.mytraccarurl.com/api/users/1
The ID and the Basic Auth are the same. And the body on raw JSON
There is a URL that makes the update for notificationsTokens?