cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
What’s new: end-to-end encryption, Replay and Dash updates. Find out more about these updates, new features and more here.

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Access Token Help

Access Token Help

jacobserroels
New member | Level 2

So I've been trying to use the API as dynamic storage for my portfolio site. Essentially I want to be able to call a folder where I store photos and when the user loads the window for a particular project have it load the photos from a path that I've specified in a JSON object. I've mostly gotten the feature to run, the issue is my Access Token keeps expiring and I want to know if there is a way in Javascript to have a permanent token or to generate one without user interaction. (I'm using the JS SDK at the moment)

3 Replies 3

Greg-DB
Dropbox Staff

Dropbox is in the process of switching to only issuing short-lived access tokens (and optional refresh tokens) instead of long-lived access tokens. You can find more information on this migration here.

Apps can still get long-term access by requesting "offline" access though, in which case the app receives a "refresh token" that can be used to retrieve new short-lived access tokens as needed, without further manual user intervention. You can find more information in the OAuth Guide and authorization documentation. You can find an example of using refresh tokens with the JavaScript SDK here.

jacobserroels
New member | Level 2

The issue is, is that from everything I can tell this is used for calling api access to someone elses files when I'm simply trying to display my own files.

Greg-DB
Dropbox Staff

The Dropbox OAuth functionality can be used for any number of users, so this works the same way if there are multiple Dropbox users, or just one. If you're the only Dropbox user, you'd just process this once to get your own refresh token.

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropbox Staff
  • User avatar
    jacobserroels New member | Level 2
What do Dropbox user levels mean?