We Want to Hear From You! What Do You Want to See on the Community? Tell us here!
Forum Discussion
Bharath_Nadig
6 years agoExplorer | Level 4
Download a file present in shared folder or group folder with team level access token
Hi,
We are using Java sdk to access apis of dropbox. Can you guys please inform us how to download content of a file present in a shared folder or group folder with team level access token.
Thanks in advance
If you're using the Dropbox Java SDK with an app with the "team member file access" permission and want to download files via the team member file access feature, you should first make a DbxTeamClientV2 with the team's access token. Then, you can call DbxTeamClientV2.asAdmin or DbxTeamClientV2.asMember, depending on your use case, to get a DbxClientV2 with the "Dropbox-API-Select-Admin" or "Dropbox-API-Select-User" header set, respectively.
You can also use DbxClientV2.withPathRoot to set the "Dropbox-API-Path-Root" header if needed. I recommend reviewing the Namespace Guide and Content Access Guide for more information on how the filesystem is structured and how to access different parts like this.
You can use the resulting DbxClientV2 to download files as desired using the DbxUserFilesRequests.download method.
1 Reply
- Greg-DB6 years ago
Dropbox Community Moderator
If you're using the Dropbox Java SDK with an app with the "team member file access" permission and want to download files via the team member file access feature, you should first make a DbxTeamClientV2 with the team's access token. Then, you can call DbxTeamClientV2.asAdmin or DbxTeamClientV2.asMember, depending on your use case, to get a DbxClientV2 with the "Dropbox-API-Select-Admin" or "Dropbox-API-Select-User" header set, respectively.
You can also use DbxClientV2.withPathRoot to set the "Dropbox-API-Path-Root" header if needed. I recommend reviewing the Namespace Guide and Content Access Guide for more information on how the filesystem is structured and how to access different parts like this.
You can use the resulting DbxClientV2 to download files as desired using the DbxUserFilesRequests.download method.
About Discuss Dropbox Developer & API
Make connections with other developers814 PostsLatest Activity: 2 years ago
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 or Facebook.
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!