2

By using the Fitbit documentation from here. I have succeeded upon the Fitbit authentication in my app with token expire time expires_in=604800. I got stuck by how to logout from the logged in account. Is there any Fitbit endpoint to do that or required to revoke the authentication token how could we achieve the logout?

Any Help much appreciated.

Vishnuvardhan
  • 5,081
  • 1
  • 17
  • 33
  • I think all you need to do is revoke the access token: https://dev.fitbit.com/docs/oauth2/#revoking-access-tokens. – hola Mar 13 '17 at 05:39
  • @hola This will not only the token from your app, but also log out the user from all logged in devices. – José Apr 02 '20 at 11:42

1 Answers1

0

yes you can revoke the access token. Here is the document.

An application can revoke the access that a Fitbit user has granted it. This endpoint conforms to RFC 7009. https://dev.fitbit.com/docs/oauth2/#revoking-access-tokens

Umair Afzal
  • 4,947
  • 5
  • 25
  • 50
  • Note that this will log you out from all sessions though: "Revoking the access token or refresh token will provide the same result. When the token is revoked, all tokens are revoked for that user. If an application has multiple sessions (web, mobile, etc.) for the same user, the revocation will remove all sessions (web, mobile, etc.) associated with that user." – José Apr 02 '20 at 11:42