Your workflow is unique 👨💻 - tell us how you use Dropbox here.
Forum Discussion
Brian S.53
9 years agoExplorer | Level 3
How do you track when only a file's contents have changed (API v2)
How would I track when a file's contents have changed remotely?
I've seen the "rev" value, but this also increments when the file is moved/renamed, and I'd like to ignore any changes not relate...
Greg-DB
Dropbox Community Moderator
9 years agoThe rev is currently the best way to track changes like this. If the rev hasn't changed, you know that the file contents have changed. If the rev has changed, the file contents may have changed.
The rev does change when a file is moved or renamed though, as you mentioned. It sounds like you'd be better suited by a hash of the file contents. The Dropbox API doesn't currently offer files hashes like this, but I'll be sure to pass this along as a feature request.
- Greg-DB8 years ago
Dropbox Community Moderator
The Dropbox API now offers a hash of file data that you can use to verify a file's contents. You can find it in FileMetadata.content_hash. It isn't a single MD5 or SHA1, but rather a combination of SHA256 hashes of the pieces of the file. You can find more information here:
https://www.dropbox.com/developers/reference/content-hash
About Dropbox API Support and Feedback
Get help with the Dropbox API from fellow developers and experts.
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!