Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
Ed F.14
7 years agoNew member | Level 2
adding team functionality to an existing dropbox app
Hello, I have an app in the app store, backpack studio, that allows access to reading and writing audio files through dropbox.... I have a user that would like me to support dropbox "teams" s...
- 7 years ago
Yes, that's right. That would use the user's folder, if they're not on a team with a team space, or the team space folder, if they are on a team with the team space. Also, note you can use initWithRoot if you do intend to access the root and want verification mentioned under the "Root" part of the "Dropbox-API-Path-Root Header Modes" section of the Namespace Guide (whereas initWithNamespaceId can be used for any particular namespace the user has access to).
Greg-DB
Dropbox Community Moderator
7 years agoIf you just want to be able to access files and folders in their "team space", you don't need to register a "Dropbox Business API" app or use the "teamRoutes". (That's for accessing functionality specific to managing Dropbox Business teams, e.g., adding or removing members.)
You can use your existing "Dropbox API" app with the "full Dropbox" permission to access files in their "team space" (that is, outside their individual purple member folder). API calls default to the member folder though, so you'll need to update your code to specify the team space if/when desired to access it. You can find more information on how this works in the Namespace Guide. That covers how to use the 'Dropbox-API-Path-Root' header to specify the team space.
In the official Dropbox API v2 Objective-C SDK in particular, you can set the 'Dropbox-API-Path-Root' header using the DBUserClient.withPathRoot method.
- Ed F.147 years agoNew member | Level 2
Thank you - so just to clarify from reading the namespace guide - would an objective c implementation that simultaniously supports users on teams and regular users not on teams work like this:
[[client.usersRoutes getCurrentAccount] setResponseBlock:^(DBUSERSFullAccount * _Nullable result, DBNilObject * _Nullable routeError, DBRequestError * _Nullable networkError) { //get the root namespace id ... will be the home folder if not on a team NSString *namespaceId = result.rootInfo.rootNamespaceId; //create a dbcommonpathroot with the namespace id DBCOMMONPathRoot *cpr = [[DBCOMMONPathRoot alloc] initWithNamespaceId:namespaceId]; // make a new client by calling client with the root object client = [client withPathRoot:cpr]; // // call to get folders etc...Or is there a simpler way i am overlooking?
- Greg-DB7 years ago
Dropbox Community Moderator
Yes, that's right. That would use the user's folder, if they're not on a team with a team space, or the team space folder, if they are on a team with the team space. Also, note you can use initWithRoot if you do intend to access the root and want verification mentioned under the "Root" part of the "Dropbox-API-Path-Root Header Modes" section of the Namespace Guide (whereas initWithNamespaceId can be used for any particular namespace the user has access to).
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!