Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
mitr1887
8 years agoExplorer | Level 3
get thumbnail from myfiles
Hi, I am trying to get thumbnail of my dropbox files via api but I am not getting how can I show same or in what result I can access the same. Please help me. In which format I would get thum...
Greg-DB
Dropbox Community Moderator
8 years agoUsing /2/files/get_thumbnail as you're doing here is the correct way to retrieve a thumbnail for a file from the Dropbox API.
Per the documentation, you can specify a 'format' parameter to request either 'jpeg' or 'png' for the format of the thumbnail. You're not specifying that, so you'll get the default of 'jpeg'.
This is a "content-download" endpoint, so the HTTP response body itself will contain the requested data, in this case, the raw data for the thumbnail. In your code, that's available in the 'data' parameter given to the 'done' callback function. Exactly what you do with that data is up to you.
Also, note that we do offer and recommend using the official Dropbox API v2 JavaScript SDK instead. That has a corresponding filesGetThumbnail method that you can use instead of calling the endpoint directly.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
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, Facebook or Instagram.
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!