简体   繁体   中英

Dropbox - How to retrieve the content of a folder

I want to get a JSON that describes the content of the folder. Dropbox API Metadata says I only need the following link address and the path to my public folder

a) LINK to Metadata + path to my folder

https://api.dropbox.com/1/metadata/auto/<path>

b) Path to my folder

https://www.dropbox.com/sh/2w...........73z4na?dl=0

if I cobined a) and b) in the browserbar I always get an ERROR:

{"error": "No auth method found."}

How is it done correctly?

The /metadata Dropbox API endpoint takes path parameter, which should be the relative path to the desired file or folder inside a user's Dropbox account. For example, this may look like "/Documents/Resume.docx". Your sample is a shared link though, which doesn't contain the necessary path.

In addition, the /metadata Dropbox API endpoint is part of the Dropbox Core API, which requires the user to first authorize a Dropbox API app to access their account. As you don't have that part done, you get that auth error.

You should work through the instructions and tutorial for whatever SDK or library you're trying to use, if any. There's also an OAuth guide for the Dropbox API that should be helpful:

https://www.dropbox.com/developers/reference/oauthguide

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM