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

raRaRa's avatar
raRaRa
Helpful | Level 6
8 years ago

Creating temporary links for a slideshow (one device)

Hi all,

 

I own a website where people can create a real-time slideshow from various social providers such as Instagram, Twitter, Facebook, etc.

 

 

I've received a couple of requests where people want to be able to display photos from a Dropbox folder, so I've been researching the Dropbox API to see what options I have.

 

I understand that Dropbox should not be used as a CDN to serve files to hundrends or millions of people, but in my case a slideshow is usually running on a single device, so I feel like the temporary link might be a good option.

 

Now straight to my question. I call list_folder to retrieve all the files in the app folder. For each file I'll need to call get_temporary_link to get a direct link to the file. Now if the directory has 100 files, then it means that I'll have to make 100 calls to the Dropbox API in order to get temporary link for all the files. I'm very concerned with the API rate limit as this might easily surpass it.

 

 

This probably means that I need to re-think my strategy.

 

Here are some ideas that I have:

1. Call get_temporary_link on demand. The slideshow javascript will call an endpoint on my website where it requests for a direct link to the picture. My endpoint then calls the Dropbox API get_temporary_link and returns it to the slideshow.

2. Somehow serve the file from Dropbox through my website. Not quite sure how I would tackle this.

3. ?

 

Any help on this will be highly apprecicated.

 

Thanks!

 

  • The Dropbox API rate limiting system is actually relatively generous. We don't have any specific numbers documented, but making 100 calls shouldn't be an issue. 

     

    Alternatively, you can download the files directly from the Dropbox API, e.g., using /2/files/download or /2/files/get_thumbnail, and then cache and serve them from your app. You would still need one call per file though.

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

    The Dropbox API rate limiting system is actually relatively generous. We don't have any specific numbers documented, but making 100 calls shouldn't be an issue. 

     

    Alternatively, you can download the files directly from the Dropbox API, e.g., using /2/files/download or /2/files/get_thumbnail, and then cache and serve them from your app. You would still need one call per file though.

    • raRaRa's avatar
      raRaRa
      Helpful | Level 6

      Thank you Greg. Much appreciated.

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,882 PostsLatest Activity: 3 years ago
325 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!