Does anyone know what the minimum expires_in value needs to be in order to refresh a token, do you have to wait until 0 or can it be refreshed before that?
Okay I understand now. I did a test and when the expires_in = 10 when you do a refresh it goes back to 1800.
Thank you for contacting us.
You can't set this expires_in value yourself. After 3600 seconds, so 1 hour it needs to be refreshed.
Thanks for the response, no I get that I can't set it myself.
What I am trying to find out is, at what value of expires_in do I need to send my token refresh request.
Some api's you can refresh the token at any time and it will reset the expires_in value back to the max time. Others you have to wait until that expires_in time has nearly ran out.
With the Lightspeed Retail API, is there a minimum expires_in value greater than 0 that will refresh the token and reset the expires_in to the max value (3600).
Sorry I didn't understand, my bad.
You can refresh the token after 10 seconds if you want. We don't have a minimum expires_in value.
I think that maybe you still don't understand my question. Let try to be more explicit.
At which value of expires_in is a new token provided and the expires_in value reset to 3600?
Is it 'expires_in: 0' ?
Or is there a more convenient point at which the token can be refreshed and the expires_in reset to 3600?
I.e. do I have to wait for an error in my application to refresh my token or can I refresh it at say 'expires_in: 60'?
Thanks @LucienVersendaal I appreciate the help 👍
Okay perfect! Pleasure to help!