Reputation: 18495
My application is only interested in changes that happen to one file in Dropbox. What is the easiest/most efficient way to watch for changes in that one file?
I know there is a long polling method, but that looks like will fire events for any changes that the app has access to. My application requires access to the entire Dropbox account as the target file is chosen by the end user from anywhere in their account. Webhooks are also not an option as this is for a Chrome extension.
Upvotes: 0
Views: 565
Reputation: 60153
I don't know if dropbox.js
supports this option yet, but the /delta
endpoint supports a path_prefix
option that would let you specify the exact path you want to follow. /longpoll_delta
takes a delta cursor, so as long as you applied a path prefix when you created the cursor, your longpoll call will only return when something at that path changes.
Upvotes: 1