Fitbit expires_in oauth2 token is always 30 days

709 views Asked by At

I'm using Implicit Grant Flow to authenticate over oauth2 and obtaining token from fitbit platform. Here is the url I'm requesting:

https://www.fitbit.com/oauth2/authorize?response_type=token&client_id=CLIENT_ID&expires_in=31536000&prompt=none&redirect_uri=REDIRECT_URL&scope=activity%20heartrate%20sleep;

Since I'm specifying expires_in=31536000 I'm looking for a 1 year validity token, but I'm receiving a response like this:

fitbit://mypersonalcallback#access_token=ey...VE&user_id=blablabla&scope=sleep+activity+heartrate&token_type=Bearer&expires_in=2567006

So my token lasts 30 days. How can I obtain a 1 year token?

Thanks!

0

There are 0 answers