Fitbit.NET icon indicating copy to clipboard operation
Fitbit.NET copied to clipboard

support new expires_in field for tokens

Open aarondcoleman opened this issue 9 years ago • 2 comments

https://community.fitbit.com/t5/Web-API/OAuth-2-0-expiresIn-value/m-p/1461298/highlight/true#M5862

aarondcoleman avatar Jul 28 '16 00:07 aarondcoleman

Should this help with the if the refresh doesn't come back in time you can try over and over, within the time limit, to get a success?

WestDiscGolf avatar Jul 28 '16 18:07 WestDiscGolf

Guessing this will need updating ...

https://github.com/aarondcoleman/Fitbit.NET/blob/async-portable/Fitbit.Portable/OAuth2/OAuth2AutoRefreshInterceptor.cs#L18

.... with a change ...

https://github.com/aarondcoleman/Fitbit.NET/blob/async-portable/Fitbit.Portable/FitbitClient.cs#L156

... which I'm not a fan of. It doesn't feel right for it to be a method on the FitbitClient directly, but happy to leave if it fits with peoples usages :-)

And here ...

https://github.com/aarondcoleman/Fitbit.NET/blob/async-portable/Fitbit.Portable/OAuth2/DefaultTokenManager.cs#L24

... as I'm guessing this is where the "retry" logic will be?

WestDiscGolf avatar Jul 28 '16 20:07 WestDiscGolf