Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
I need to keep my local file and dropbox file in sync, so I want them to have the same timestamp.
So I have a file with timestamp displayed in Internet Explorer of:
22/06/2018 13:05:28
So when I upload it, I use the ClientModified field and set it to:
2018-6-22T13:5:28Z
I can browse the file in the dropbox app and in there it also displays 22/06/2018 13:05:28
So far so good... my local file and and the dropbox file match when looked at in explorer/dropbox windows.
When I download the file from dropbox and check the ClientModified field it says
2018-06-22T12:05:28Z
Exactly 1 hour out...Any ideas why that is and how I get around it?
Could it be related to the the fact my I am in the UK and we are currently in BST, exactly 1 hour ahead of GMT?
Thanks
I need to keep my local file and dropbox file in sync, so I want them to have the same timestamp.
So I have a file with timestamp displayed in Internet Explorer of:
22/06/2018 13:05:28
So when I upload it, I use the ClientModified field and set it to:
2018-6-22T13:5:28Z
I can browse the file in the dropbox app and in there it also displays 22/06/2018 13:05:28
So far so good... my local file and and the dropbox file match when looked at in explorer/dropbox windows.
When I download the file from dropbox and check the ClientModified field it says
2018-06-22T12:05:28Z
Exactly 1 hour out...Any ideas why that is and how I get around it?
Could it be related to the the fact my I am in the UK and we are currently in BST, exactly 1 hour ahead of GMT?
Thanks
Hey there @Splinter - nice catch!
Should the date modified time appear not to match the time you'd expect based on your timezone I would advise to perform the following steps.
Firtsly, confirm that ‘Automatically detect timezone’ is checked on your profile's page and make sure that the timezone of your computer is set correctly too.
If this issue persists after my suggestions, do let me know and we'll take it from there. Thanks!
Walter
Community Moderator @ Dropbox
dropbox.com/support
Did this post help you? If so, give it a Like below to let us know.
Need help with something else? Ask me a question!
Find Tips & Tricks Discover more ways to use Dropbox here!
Interested in Community Groups? Click here to join
Hi Walt,
Thanks for your reply. It is my first time using the forum and I realised I had posted in the wrong section. I am using the Dropbox API and have subsequently posted into the developers/API section:
Should I do something with the post on this forum - delete or close it somehow?
Hey @Splinter - thanks for the heads up!
I moved your original post here as well to keep things neat - no further actions are needed from your end, no worries.
As per your API related question, make sure to subscribe to this thread so you'll get an update when a member of my team writes back here with more information about the issue you seem to be having.
If there's anything else I can do to help, do let me know.
Cheers!
Walter
Community Moderator @ Dropbox
dropbox.com/support
Did this post help you? If so, give it a Like below to let us know.
Need help with something else? Ask me a question!
Find Tips & Tricks Discover more ways to use Dropbox here!
Interested in Community Groups? Click here to join
Great thanks for correcting my mistake Walt ![]()
I'll wait to hear back from your team about the ClientModified issue - I hope they have some ideas as I'm a bit stumped as to why dropbox will accept "2018-6-22T13:5:28Z" on /upload, but return "2018-6-22T12:5:28Z" on /download.
@Splinter Can you share the code you're using to reproduce this, and the output you're getting? I just tried to reproduce this and /download is returning the same datetime I'm supplying to /upload in a simple test:
curl -vX POST https://content.dropboxapi.com/2/files/upload \
--header 'Authorization: Bearer <ACCESS_TOKEN>' \
--header 'Content-Type: application/octet-stream' \
--header 'Dropbox-API-Arg: {"path":"/test_281598","client_modified":"2018-6-22T13:5:28Z"}'
# > POST /2/files/upload HTTP/1.1
# > Host: content.dropboxapi.com
# > User-Agent: curl/7.58.0
# > Accept: */*
# > Authorization: Bearer <ACCESS_TOKEN>
# > Content-Type: application/octet-stream
# > Dropbox-API-Arg: {"path":"/test_281598","client_modified":"2018-6-22T13:5:28Z"}
# >
# < HTTP/1.1 200 OK
# < Server: nginx
# < Date: Fri, 22 Jun 2018 17:21:40 GMT
# < Content-Type: application/json
# < Transfer-Encoding: chunked
# < Connection: keep-alive
# < Vary: Accept-Encoding
# < pragma: no-cache
# < cache-control: no-cache
# < X-Server-Response-Time: 989
# < X-Dropbox-Request-Id: 7d064252bd53bd317bb02605d8ed4fd9
# < X-Robots-Tag: noindex, nofollow, noimageindex
# <
# * Connection #0 to host content.dropboxapi.com left intact
# {"name": "test_281598", "path_lower": "/test_281598", "path_display": "/test_281598", "id": "id:25N5ksooX-sAAAAAAAMpmw", "client_modified": "2018-06-22T13:05:28Z", "server_modified": "2018-06-22T17:21:40Z", "rev": "733c4021eccc7", "size": 0, "content_hash": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"}
curl -vX POST https://content.dropboxapi.com/2/files/download \
--header 'Authorization: Bearer <ACCESS_TOKEN>' \
--header 'Dropbox-API-Arg: {"path":"/test_281598"}'
# > POST /2/files/download HTTP/1.1
# > Host: content.dropboxapi.com
# > User-Agent: curl/7.58.0
# > Accept: */*
# > Authorization: Bearer <ACCESS_TOKEN>
# > Dropbox-API-Arg: {"path":"/test_281598"}
# >
# < HTTP/1.1 200 OK
# < Server: nginx
# < Date: Fri, 22 Jun 2018 17:22:13 GMT
# < Content-Type: application/octet-stream
# < Content-Length: 0
# < Connection: keep-alive
# < accept-ranges: bytes
# < etag: W/"733c4021eccc7"
# < pragma: no-cache
# < cache-control: no-cache
# < original-content-length: 0
# < dropbox-api-result: {"name": "test_281598", "path_lower": "/test_281598", "path_display": "/test_281598", "id": "id:25N5ksooX-sAAAAAAAMpmw", "client_modified": "2018-06-22T13:05:28Z", "server_modified": "2018-06-22T17:21:40Z", "rev": "733c4021eccc7", "size": 0, "content_hash": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"}
# < X-Server-Response-Time: 1497
# < X-Dropbox-Request-Id: 0ff75dbf9fb1eab7c7ecefbf2c5ce379
# < X-Robots-Tag: noindex, nofollow, noimageindex
# <
# * Connection #0 to host content.dropboxapi.com left intact
So, it looks like this is working as expected at the API level, but perhaps you're using an SDK or library and there is a time zone issue at that level. If so, please make sure to include the SDK/library name and version too. Thanks!
Hi there!
If you need more help you can view your support options (expected response time for a 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!