We don't have any UI yet for selecting expiration time.
Will there be any way to set the expiration time for token in the config file ?
That would be a nice middle around. We have some fixed workstations that display locations on televisions. The tokens we used to request in the gui worked fine. The tokens we request in the gui work fine today except you have to redo them every 7 days. It makes it harder for fixed
Applications
I tried going through the api guide but could not locate tokens under sessions - but then this is not my area of expertise.
Implemented an option to set token expiration:
https://github.com/traccar/traccar-web/commit/6691ae65db37165fe61fd14ec8047052bf10ccae
Anton...
I downloaded and installed 5.4 today. On the individual user object I selected the user and on the preferences I set a expiration time under the token expiration date of 3 years.
I then clicked the arrow to log in as that user account, and then on account I clicked the generate token button.
When I base 64 decode the token it still shows a 7 day expiration period.
I tried reviewing the code - am I not using this correctly.
Just tested. It's working correctly for me.
Maybe you can tell me what I'm doing wrong.
Here are the screen shots.
This is the token.
RzBFAiEA8OKgxAu9JrOZrT4XsSqBszIpwgj_LfBnTEsFLdSRy6ECIHjO48l7Gp1zjH0_VKNvevBRMGTBnxwN2uAoe0lizndReyJ1Ijo3LCJlIjoiMjAyMi0xMC0xM1QxNDoyMTo0OS40ODArMDA6MDAifQ
I appreciate you looking at it - we've had our displays for ambulance tracking offline for sometime.
This is NOT 5.4. Are you sure you cleared your browser cache?
Interesting - I did not know that was required. I just updated, reconnected to my sql, and then verified in the server log that 5.4 was displayed.
That was always required. And it's not something specific to Traccar. In general your browser caches websites.
Hello everyone...
We have been using Traccar for quite sometime - and have had users with API tokens for our systems. These tokens were created in the previous web interface.
We have recently installed a brand new 5.3 installation and now our tokens are expiring (which is to be expected) every 7 days.
We need to obtain longer term tokens for these other systems we work with - but quite frankly we're not API type users.
Does anyone have pre-made code that we might try to recycle to do this? Will creating tokens that last longer than 7 days come back to the web interface for those of us that have partners but are not code savy?