cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Are you interested in hearing how one of our Community members uses Dropbox for sailing trips? Read all about it 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: 

Re: Get list of files in folders inside shared folders

Re: Get list of files in folders inside shared folders

mdiazl
Helpful | Level 5
Go to solution

Hi, it seems a bit old post, but I will try 🙂.

So it is not possible to download a shared file using the Dropbox library for Python?

If I use "files_download_to_file", I only see as "entry" the container folder but not the file that it contains. From the web I can see the folder and the file inside.
Any idea?

1 Accepted Solution

Accepted Solutions

mdiazl
Helpful | Level 5
Go to solution

@Greg-DB Using " files_download_to_file" looks like it is not able to find the file shared. So I used the function to list all files that are within a folder ("files_list_folder") to be sure that the file was there, at this point,  I realized that it only returns me as entry the name of the folder.

I tried also several options modifying its parameters such as "include_has_explicit_shared_members" or "include_mounted_folders" but the result was the same.
The authentication was another war but finally it was solved.
For the file, I created shared_link(with the user of the app) and it works correctly, I don't know why the first approach doesn't work, in any case now it is working.
Thanks for your time.

View solution in original post

2 Replies 2

Greg-DB
Dropbox Staff
Go to solution

@mdiazl You should be able to download a file in the connected account using the files_download_to_file method. That should work for files in shared folders as well, as long as the shared folder is mounted in the connected account. Alternatively, if you want to download a file from a shared link, you would instead use sharing_get_shared_link_file.

 

There are a few forms of sharing on Dropbox and it's not completely clear what the set up is in your case, so please share some more information if you need help with this. For example, please share the relevant code you're running and the output you're getting so we can take a look. Be sure to redact any refresh token, access token, or app key/secret though.

mdiazl
Helpful | Level 5
Go to solution

@Greg-DB Using " files_download_to_file" looks like it is not able to find the file shared. So I used the function to list all files that are within a folder ("files_list_folder") to be sure that the file was there, at this point,  I realized that it only returns me as entry the name of the folder.

I tried also several options modifying its parameters such as "include_has_explicit_shared_members" or "include_mounted_folders" but the result was the same.
The authentication was another war but finally it was solved.
For the file, I created shared_link(with the user of the app) and it works correctly, I don't know why the first approach doesn't work, in any case now it is working.
Thanks for your time.

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    mdiazl Helpful | Level 5
  • User avatar
    Greg-DB Dropbox Staff
What do Dropbox user levels mean?