You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.

Forum Discussion

YanivB's avatar
YanivB
Helpful | Level 6
11 months ago

reauthorizeClient

Hi,

i get access token in my ios app using dropbox api.
i want to reauthenticate in the same app on other device using these access token. 

How can it be done (in Swift code lang) ? 

all works in the first device i did the all 
OAuth process, but not working when I try to reauthorizeClient with the access token from the first device...

  • YanivB's avatar
    YanivB
    11 months ago

    You are awesome !

    Thanks the guidance.

  • The reauthorizeClient method would set the authorizedClient to use an access token that's already been stored. If you haven't stored the relevant access token, then that won't work. (The built-in OAuth functionality would automatically store the access token, but that won't occur automatically if you copied it from another device.)

     

    To store an access token, you can use DropboxOAuthManager storeAccessToken, and then use reauthorizeClient.

      • Greg-DB's avatar
        Greg-DB
        Icon for Dropbox Staff rankDropbox Staff

        I don't believe we have example code for using that. Perhaps you could share the relevant piece of code you have so far and show what you're stuck on (e.g., any unexpected error/output)? Be sure to redact any actual access/refresh tokens though.

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,888 PostsLatest Activity: 2 days ago
326 Following

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!