0
PurgeXenos
139d

I need to refresh my Access Token from Flutter app. Should I use token expiry field from Access Token or attempt a request and if get 401 and some error from auth0, refresh token and try again?

Comments
  • 1
    I feel the latter. Since you are making a request anyway.

    That way your client doesn't have to deal with parsing the token
  • 3
    Both actually
  • 0
    @iceb Client already has expiry, Auth0 returns that field. Backend dudes says to use that field... I am not sure
  • 0
    @Hazarth Hardcore :)
  • 0
    i mean backend should be checking the expiry regardless.

    If it's sent back plain, it doesn't take much to check on client. It just doesn't feel necessary
Add Comment