We are aware of the issue with the badge emails resending to everyone, we apologise for the inconvenience - learn more here.

Forum Discussion

neunygph's avatar
neunygph
Explorer | Level 4
8 years ago

Response headers

Hi,

 

With API v2, we can be able to access/retrieve response header from get_thumbnail request in order to retrieve "etag" and "dropbox-api-result". I just start using  Dropbox SDK from http://dropbox.github.io/dropbox-sdk-js/global.html#FilesThumbnailArg__anchor and I was trying to get the response header but look like there is no way for me to access response header from "DropBox.filesGetThumbnail()".

 

Just wonder if there is a way to do it with the SDK

 

Thanks,

  • Greg-DB's avatar
    Greg-DB
    8 years ago
    Yes, if there have been any changes to the file, the rev will be different.
  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Staff rankDropbox Staff

    The JavaScript SDK doesn't expose these directly. Instead, the information from the filesGetThumbnail response is translated into a JavaScript object for you. Likewise, the etag value is available as the "rev" metadata.

    • neunygph's avatar
      neunygph
      Explorer | Level 4
      Hello Greg,

      So that mean we can use the rev value as an etag to check if the file has been modified since the last request, is that correct ?
      Thanks,
      • Greg-DB's avatar
        Greg-DB
        Icon for Dropbox Staff rankDropbox Staff
        Yes, if there have been any changes to the file, the rev will be different.

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,877 PostsLatest Activity: 8 hours 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!