Learn how to make the most out of the Dropbox Community here 💙.
Forum Discussion
Vang G.
8 years agoExplorer | Level 3
Notify When File Change
Hi Dropbox Team, After I migrated from DB api V1 to V2, I have a problem about sync files. I don't know when the file is changed from Dropbox. Please help me. Thanks, Vang Doan
Greg-DB
Dropbox Staff
8 years agoIf you're building a server-side app, the best way to know when things change is to use webhooks:
https://www.dropbox.com/developers/reference/webhooks
If you're building a client-side app, the best way to know when things change is to use /2/files/list_folder/longpoll: (or the respective method in whatever SDK/library you're using, if any)
https://www.dropbox.com/developers/documentation/http/documentation#files-list_folder-longpoll
If you're running in to trouble getting the API working with your app, I'll be happy to help with any issues you're having, but I'll need some more information. Please reply with:
- the name and version of the platform and SDK/library you are using, if any
- the full text of any error or output
- the steps to reproduce the issue, including the relevant code snippet(s)
https://www.dropbox.com/developers/reference/webhooks
If you're building a client-side app, the best way to know when things change is to use /2/files/list_folder/longpoll: (or the respective method in whatever SDK/library you're using, if any)
https://www.dropbox.com/developers/documentation/http/documentation#files-list_folder-longpoll
If you're running in to trouble getting the API working with your app, I'll be happy to help with any issues you're having, but I'll need some more information. Please reply with:
- the name and version of the platform and SDK/library you are using, if any
- the full text of any error or output
- the steps to reproduce the issue, including the relevant code snippet(s)
- Vang G.8 years agoExplorer | Level 3Hi Greg K.,
I tried with
https://www.dropbox.com/developers/documentation/http/documentation#files-list_folder-longpoll, But it work incorrect, I dont know exactly what files change when I delete.
Unlike Api v1.
Please help me :(
Thanks,
Vang Doan- Vang G.8 years agoExplorer | Level 3Hi Greg K.
Im working on iOS platform.
Thanks,
Vang Doan- Greg-DB8 years ago
Dropbox Staff
The /2/files/list_folder/longpoll endpoint tells you when something has changed in the linked account, but it doesn't tell you exactly what changed. (This is the equivalent of API v1's /1/longpoll_delta.)
You should then call /2/files/list_folder[/continue] to find out what changed. (This is the equivalent of API v1's /1/delta.)
Note that if you're using an SDK, there will be corresponding methods for each of these endpoints.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.5,965 PostsLatest Activity: 23 hours ago
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!