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: 

How can I update client_modified for a file through the API?

How can I update client_modified for a file through the API?

Jostein J.
Helpful | Level 5

I would like to update all the client_modified timestamps of my media files so that the image gallery app I'm using sorts the files in correct chronological order (it uses client_modified, and not exif data or similar for sorting). I would think this should be possible somehow but I can't figure out how.

 

Is it possible? The only workaround I know of is to temporarily move the file(s) to another folder (outside of Dropbox), then wait for Dropbox to register it as deleted, and then move the file(s) bak into the folder they were.

 

I'm using the Python SDK.

2 Replies 2

Greg-DB
Dropbox Staff

This is technically possible, but there are a few complicating factors:

  • The only way to update client_modified is to perform an upload of the file with client_modified set.
  • If you upload the same exact file data to an existing file, Dropbox won't consider this a change (since the file data didn't change) and so won't commit new metadata (such as an updated client_modified).

That being the case, you can make these changes, but you'll need to do so like you described, that is, by performing the upload with client_modified set, but as a new or changed file. (I'll send this along as a feature request for an easier/more efficient way to do this, but I can't promise if or when that might be implemented.)

Jostein J.
Helpful | Level 5
Thanks!

That would be quite useful to have in the API.
Need more support?
Who's talking

Top contributors to this post

  • User avatar
    Jostein J. Helpful | Level 5
  • User avatar
    Greg-DB Dropbox Staff
What do Dropbox user levels mean?