question

brokenoval avatar image
brokenoval asked miket-mavn commented

Is there an expiry time for access_tokens?

How long do access_tokens live for?

Do we need to refresh tokens every so often from a Web App?

Is there a difference for web app tokens and tokens from the device?

So far the only reference to token expiry I can find is in this question: http://devask.clover.com/question/969...

1 comment
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

miket-mavn avatar image miket-mavn commented ·

This would be a worthy addition to the documentation.

0 Likes 0 ·

1 Answer

Mike M avatar image
Mike M answered

Currently, access tokens last a very long time, on the scale of a year. This is expected to change though and should not be behavior that is relied upon for your app to work. When it does change, we will be sure to let everyone know; the expiration time of the access token will likely be passed along with the token. For the interim, please either securely cache the token and handle the error code response for it needs to be refreshed for web apps, or request a token every time the app (android or web) is opened.

Clover Android apps use the Android AccountManager for caching tokens, but it should still be the same type of access token that you would receive via web api.

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community