@nevermindx wrote:...actually do we need to refresh ? ...
NO, actually you do not. The mentioned method gets executed internally whenever needed. Just init your Dropbox object with the instance of DropboxAuth, you already have (as discussed in the other thread), and... that's it - further do call methods there according what you need to do - Dropbox object' methods only. 😉
Hope this helps.
Thank you for the support🤝
Sorry if this seems like a basic question. Could you explain the situations in which we should use the refreshAccessToken() and checkAndRefreshToken() functions?
@Здравко wrote: @nevermindx wrote:...actually do we need to refresh ? ...NO, actually you do not. The mentioned method gets executed internally whenever needed. ...
NO, actually you do not. The mentioned method gets executed internally whenever needed. ...
Hm... What's not clear enough. 🤔 The conclusions seems clear enough (at least to me), but I will say it explicitly: NEVER - you don't need to call either refreshAccessToken or checkAndRefreshAccessToken by your own. By the way refreshAccessToken is called by checkAndRefreshAccessToken and checkAndRefreshAccessToken is called by all request calls of Dropbox class.
Edit: Little extrapolation was here. Actually it's not called by all request calls. Calls that need application authentication don't make such a call (actually there is a call but result is ignored - little imperfection here) because... it's just not needed - there neither access token nor refresh token are in use. I'm saying this just for completeness.