cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Are you interested in hearing how one of our Community members uses Dropbox for sailing trips? Read all about it 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: 

Getting multiple thumbnails of multiple files at once ?

Getting multiple thumbnails of multiple files at once ?

neunygph
Explorer | Level 4

Is it possible to retrieve multiple thumbnails of multiple files at once ? I tried to make a request to https://photos.dropbox.com/thumbnails_batch just like the guide from https://blogs.dropbox.com/tech/2014/01/retrieving-thumbnails/ but it doesnt' work and I'm not sure if I did it wrong or this end point is no longer supported. 

 

I tried to make a get request to https://photos.dropbox.com/thumbnails_batch?paths= /path/to/thumb0.jpg,/path/to/thumb1.jpg,[...],/path/to/thumbN.jpg but it showed 4xx error. Please advice if I missed anthing from this request.

 

Thank you

27 Replies 27

Greg-DB
Dropbox Staff
That isn't part of the public Dropbox API, which doesn't currently offer a bulk thumbnails call, but I'll be sure to pass this along as a feature request.

neunygph
Explorer | Level 4
Hi Greg,

Thanks for the quick response, I am aware that https://photos.dropbox.com/thumbnails_batch is not a public Dropbox API endpoint but is there a way or any public API end point to get multiple thumbnails at once ?

Thanks,

Greg-DB
Dropbox Staff
No, the Dropbox API doesn't currently offer a way to get thumbnails in bulk.

neunygph
Explorer | Level 4
Ah ok, thanks Greg for the info.

neunygph
Explorer | Level 4
Hi Greg,

I'm trying to get a thumbnail for an image in my account and make a POST request to https://api.dropboxapi.com/2/files/get_thumbnail, and it successfully returned with a status 200, which is good. But from the json response, I do not see any link or url to this thumbnail. Also, regardless what size or format option I put in, the returned data is always showing that the thumbnail is the same size and the format is always the original format when uploaded.

For instance, I uploaded a .jpeg or jpg image. Is it possible to retrieve a .png thumbnail and the size other than the original uploaded size ? And where do I find the link/url for this thumbnail from the response. Please advice.

Thank you

Greg-DB
Dropbox Staff

The /2/files/get_thumbnail endpoint returns the raw thumbnail data directly in the response body, not as a URL. You'll want to read the response body out and save or display that as the thumbnail. The API doesn't offer a way to get links for thumbnails, but I'll be sure to pass this along as a feature request. 

 

Also, the JSON in the dropbox-api-result header is the metadata for the original file itself, not the returned thumbnail data.

neunygph
Explorer | Level 4
Look like the api version 1 support thumbnails url, I'm just wondering when v1 will be deprecated or no longer in use anymore?

Greg-DB
Dropbox Staff

The API v1 /thumbnails endpoint also only returns the data, not a URL.

 

You can find the deprecation timeline for API v1 here:

 

https://blogs.dropbox.com/developers/2016/06/api-v1-deprecated/

neunygph
Explorer | Level 4
Hi Greg,

According to the document from https://www.dropbox.com/developers-v1/core/docs#thumbnails, I implemented the api v1 to get an image thumbnail and I got this and I am able to display the thumbnail with this active url https://api-content.dropbox.com/1/thumbnails/auto/IMG_8199.jpg?size=l&access_token={mytoken}. So I'm wondering if there is a replacement for v2 with a similar URL like the one from https://api-content.dropbox.com/1/thumbnails/auto/IMG_8199.jpg?size=l&access_token={mytoken}.

Thanks,
Need more support?
Who's talking

Top contributors to this post

  • User avatar
    neunygph Explorer | Level 4
  • User avatar
    Greg-DB Dropbox Staff
What do Dropbox user levels mean?