cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to learn some quick and useful tips to make your day easier? Check out how Calvin uses Replay to get feedback from other teams at Dropbox 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: 

Export all files/folders on a given dropbox.com account to CSV

Export all files/folders on a given dropbox.com account to CSV

rk90
Helpful | Level 5
I am working on a CLI app that will use a team admin token to export the entire data structure (including team folders, shared folders and members' personal folders) on a given dropbox.com account.

I am using Python SDK and getting duplicated entries. That is, when I list team folders, I get the list of all team folders, then I list each member's root folders and I get their personal folders along with shared folders and team folders that were listed previously when I first listed the team folders.

How would I get a unique listing of files/folders? I've read about user's root and team space but I wouldn't know whether team is sharing a team space.
1 Reply 1

Greg-DB
Dropbox Staff

To de-duplicate these entries, you should use the namespace ID for each shared/team folder. I.e., the "shared folder ID" or "team folder ID". These IDs will be consistent across user accounts, even if the path of the folder is not.

You can determine if a user is on a team that uses the "team space" by checking the FullAccount.root_info returned by users_get_current_account. You can check if the type of the RootInfo is a TeamRootInfo or a UserRootInfo. Check out those links for more information on that.

I also recommend reviewing the Namespace Guide and Content Access Guide for more information, if you haven't already.

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropbox Staff
What do Dropbox user levels mean?