cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Back again with another edition of 'How we use Dropbox', so find out how Emma uses to-do lists to get it all done 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: 

Able to poll for Shared Folders after user Adds to Dropbox but not Shared Files - Java SDK

Able to poll for Shared Folders after user Adds to Dropbox but not Shared Files - Java SDK

apo1397
Explorer | Level 4

Hi,
I'm using the Java Core SDK version 3.1.3 
We have a mechanism of long polling for the changes in the User's Account.
Our Application doesn't have any of the scopes for teams .
For a regular user (Non Team) we're able to get the "events" for a shared folder if the user chooses to "Add to Dropbox"
But we're not getting the shared files using the cursor to get the changes using the following API

files().listFolderContinue(cursor);

  The files don't have an option to "Add to Dropbox" (atleast at the receiver's end) .
So how do we go about knowing if a file has been shared to an account ?
Continuously comparing all shared files using 

sharing().listReceivedFiles()

isn't a good idea since our users have thousands of files.
Using the Business APIs is a different beast but if someone can tell me how to use the Long Poll method / webhook for shared files that would be great .

3 Replies 3

Re: Able to poll for Shared Folders after user Adds to Dropbox but not Shared Files - Java SDK

Greg-DB
Dropboxer

Unfortunately the Dropbox API doesn't offer a way to continuously monitor "received" shared files (like webhooks or longpolling), but I'll pass this along as a feature request. I can't promise if or when that might be implemented though. 

 

Using the listReceivedFiles/listReceivedFilesContinue methods is the right way to see what files the account has received. You can get a ListReceivedFilesBuilder as returned by listReceivedFilesBuilder to use ListReceivedFilesBuilder.withLimit to increase how many files you get back per call though, if that helps.

Re: Able to poll for Shared Folders after user Adds to Dropbox but not Shared Files - Java SDK

apo1397
Explorer | Level 4

Thanks for the reply @Greg-DB . I read somewhere about the Business APIs being of some help but I didn't see any API to continuously monitor "received" shared files. 
Did the documentation mean that we might get shared files in the webhook/longpoll for Dropbox Business Account or something else ?

Re: Able to poll for Shared Folders after user Adds to Dropbox but not Shared Files - Java SDK

Greg-DB
Dropboxer

Are you referring to the getEvents/getEventsContinue functionality? That's a way to monitor events occurring on a Dropbox Business team. That log would include shared file events, but it can only be used by Business teams, with the 'events.read' team scope.

Poll
We love to learn from the educators who use Dropbox. Whether you teach kids, teens, adults or a combination of all three, we want to know what apps and integrations you use with Dropbox to help with teaching. Which of the ones below is your favorite, or most used tool?
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropboxer
  • User avatar
    apo1397 Explorer | Level 4
What do Dropbox user levels mean?
Need more support?