cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Tell us what you want to see on the Community here!
Close

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: 

API V2 Access team folders of bussines plan with Folder/Files operations

Highlighted

API V2 Access team folders of bussines plan with Folder/Files operations

New member | Level 2

 i want to acces team folders using application user api for list,create folders, upload and download,etc.. and i'm going crazy.

In API Explorer  with function "list_folder",  only can acces user home folder, y try put in path the id of shared id,or namespace ns; does not work either,

The only way can view team folder stuff is put the shared link root, but the result of folders not contains the field path o lower_path ,that needs to files/folder operations like create folders/download/upload files etc..

 

Also try create folders / upload whith namespace ns: and return no write acces,the team folders have editor permissions.

 

I can't see any function to upload or create folders into shared folders.

 

I see this folders are mounted and can't unmounted it , theoricaly they would have to appear like shared folders when are mounted  when use function "list_folder"

 

can help me?

thnks

 

1 Accepted Solution

Accepted Solutions
Highlighted

Re: API V2 Access team folders of bussines plan with Folder/Files operations

Dropboxer

It sounds like you're using a Business team with the new team space and member folders configuration that some teams have access to.

 

That being the case, you'll need to specify the team folder specifically when making API calls to access its contents, for example, by supplying the 'Dropbox-API-Path-Root' header. You can find more information on that here:

 

https://www.dropbox.com/developers/reference/namespace-guide

 

The Dropbox API Explorer is built for the older configuration, but we're working on updating the API and SDK support and documentation to support the new one. That's not quite ready yet though, so unfortunately there isn't a good way to use the API Explorer for this right now, but you can run it outside the of Explorer. Apologies for the inconvenience!

View solution in original post

5 Replies 5
Highlighted

Re: API V2 Access team folders of bussines plan with Folder/Files operations

Dropboxer

It sounds like you're using a Business team with the new team space and member folders configuration that some teams have access to.

 

That being the case, you'll need to specify the team folder specifically when making API calls to access its contents, for example, by supplying the 'Dropbox-API-Path-Root' header. You can find more information on that here:

 

https://www.dropbox.com/developers/reference/namespace-guide

 

The Dropbox API Explorer is built for the older configuration, but we're working on updating the API and SDK support and documentation to support the new one. That's not quite ready yet though, so unfortunately there isn't a good way to use the API Explorer for this right now, but you can run it outside the of Explorer. Apologies for the inconvenience!

View solution in original post

Highlighted

Re: API V2 Access team folders of bussines plan with Folder/Files operations

New member | Level 2

HI Greg,

I have the same problem of accessing team shared folder. 

I tried to follow the namespace guide. I am using python. First get namespace ids:

"root_namespace_id": "4345996448",
"home_namespace_id": "4770419568",

Then create dbx object with a header:

header = {'Dropbox-API-Path-Root': {".tag": "namespace_id", "namespace_id": "4345996448"}}
dbx = dropbox.Dropbox(TOKEN, header)

But when do a 

dbx.files_list_folder('')

still showing my user's home dir, not team shared one. If I add 'ns:4345996448' to PATH, it would fail.

 

Can you help me with it? Thanks.

Highlighted

Re: API V2 Access team folders of bussines plan with Folder/Files operations

Dropboxer

@tianhong To set the 'Dropbox-API-Path-Root' header, you should instead use the provided 'Dropbox.with_path_root' method, like this:

dbx = dropbox.Dropbox(TOKEN).with_path_root(dropbox.common.PathRoot.namespace_id("1990815600"))
dbx.files_list_folder('')
Highlighted

Re: API V2 Access team folders of bussines plan with Folder/Files operations

New member | Level 2

Thanks Greg! It works. 

I am just wondering how to search these kinds of information in the documentation. I tried but failed. I don't think asking questions here is an efficient way, although your help is great.

Highlighted

Re: API V2 Access team folders of bussines plan with Folder/Files operations

Dropboxer

@tianhong Thanks for the feedback! The documentation for the Python SDK is linked from the SDK's readme, and all of the options for the `Dropbox` class can be found on this `Dropbox` documentation page in particular. I certainly understand how that may not be very discoverable though, so we'll think about ways to make that better.

Work Smarter with Dropbox

The way we work is changing. Share and discover new ways to work smarter with Dropbox in our community.

Sound good? Let's get started.
Who's talking

Top contributors to this post

What do Dropbox user levels mean?
Need more support?