Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
prabhat1999
2 years agoExplorer | Level 3
finding the path of shared folders
I am using dbx.sharing_list_folders() function to get all the shared folder and using folder_metadata= dbx.sharing_get_folder_metadata(shared_folder.shared_folder_id) to get the meta data of the sha...
iNeil
Dropbox Community Moderator
2 years agoHello prabhat1999 ,
If your account has the updated team configuration and you are not using the Dropbox-API-Path-Root header with the Dropbox API, the team folders and any folders nested within them won’t return the path_lower field. Additionally, if your shared folder is unmounted, it won't return the path_lower field either. This could be the reason why your path_lower value is “None”.
That said, you could use the sharing_list_folders method directly to retrieve some of your path_lower values instead of looping the sharing_get_folder_metadata method with the shared_folder_id. Below I have provided an example code snippet while using the Dropbox-API-Path-Root header.
# Create a Dropbox instance with an access token and using the Dropbox-API-Path-Root header
dbx = dropbox.Dropbox('ACCESS_TOKEN')
root_namespace_id = dbx.users_get_current_account().root_info.root_namespace_id
dbx = dbx.with_path_root(dropbox.common.PathRoot.root(root_namespace_id))
# Call the sharing_list_folders method
result = dbx.sharing_list_folders()
# Print the list of shared folders path lower value
for entry in result.entries:
print(entry.path_lower)
About Discuss Dropbox Developer & API
Make connections with other developers
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
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, Facebook or Instagram.
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!