Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
Hi,
I have 42 folders in my Web Dropbox. 43 if you count the deleted folder. When I use either /list_folders or /list_mountable_folders I get 88 folders returned in the JSON string. The other 46 (more than I actually have) are for folders I may have been involved in a share, may have created for testing, probably deleted more than 2 years ago, ie. most if not all were created for testing purpose. They include names like the windows default New Folder (3). Hardly anything I'm likely to retain?
Three questions:
Any assistance appreciated.
1. It sounds like you're referring to using the endpoints /2/sharing/list_folders[/continue] and /2/sharing/list_mountable_folders[/continue]. The /2/sharing/list_folders[/continue] endpoints will return shared folders you currently have in your account. The /2/sharing/list_mountable_folders[/continue] endpoints will return shared folders you can use, even if they are not currently mounted in your account. For example, these would be shared folders you were invited to but never added to your account, or deleted from your account.
2. If you want to remove these old shared folders, you can use /2/sharing/relinquish_folder_membership.
3. If you want to just list the current contents of your account, you should use /2/files/list_folder[/continue] instead. Note that it's under /files, instead of /sharing. Supply a path of the empty string "" if you want to list everything in the root folder.
Hi Greg,
Thanks for the response.
OK, 1. sounds strange, I have no idea why this would be remotely useful or, more importantly, why it would be the default return.
2. Yes, but that means I have to identify and individually call every folder. We are writing an application that when deployed, it will have no idea which folders should or should not be relinquished.
3. I've tried this, but keep getting a bad request (400) when passing an empty string. We are using delphi and I've tried initialising a variable to '"" and setting the values to '/2/files/list_folder ' + VARIABLE and I've also tried '/2/files/list_folder ""'. both return the bad request error.
I will persevere with that option and see what I can get to work.
Kevin
Greg,
Yes, I finally figured that out with your advice and a working example and am now getting parameters passed and a 200 return code. Thanks for the heads up.
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 Twitter or Facebook.
For more info on available support options, see this article.
If you found the answer to your question, please 'like' the post to say thanks to the user!