Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
Hi ... I m working with the Dropbox api using C# . i want to display dropbox folder image to asp.net C# web page.How i can do it plz help me guys
Dropbox does offer an API you can use for listing, uploading, and downloading files, among other operations. You can find everything you need to get started with the Dropbox API, including documentation, tutorials, and SDKs here.
For .NET in particular, we recommend using the official Dropbox API v2 .NET SDK. The page there has information on how to get started with that, and includes links to a few example apps.
For instance, to use that to list the contents of any particular path, you would use ListFolderAsync/ListFolderContinueAsync. There's an example of calling ListFolderAsync here. And to download the data of any particular file, you would use DownloadAsync. There's an example of that here.
I have a dropbox api with token and app secret key . the code is giving me error when i fetching data from dropbox folder.
private void getfiles()
{
RequestResult strReq = OAuthUtility.Get
(
"https://api.dropboxapi.com/2/cloud_docs/get_metadata", new HttpParameterCollection
{
{ "Eziline Screenshot/Fazal/07-Jul-20 4:37:22 PM .JPG", "FilePath" },
{ "sl.AewflY8ByI3m3xIEG0-nrBXfze7nGULFcNyS2qPjYrrHGR7Qpv9fkcZJRXxUdLzspinuJqSA", "AccessToken" }
}
);
if (strReq.StatusCode == 200)
{
Image1.ImageUrl = "Eziline Screenshot/Fazal/07-Jul-20 4:37:22 PM .JPG";
}
}
i have used Nemerio OAuth . it is giving me error
Nemiro.OAuth.RequestException: 'The remote server returned an error: (400) Bad Request.'
[Cross-linking for reference: https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/How-to-Show-image-of-dropbox-in-asp-net... ]
I see you're getting a 400 error code, but you should also print out the response body itself, as it would contain a more useful error message. We can't provide support for the Nemerio OAuth library itself though, as it's not made by Dropbox.
Also, if you want the metadata for any particular file or folder, you should instead call /2/files/get_metadata.
By the way, do not share or post your access token. (This one is short-lived though, and would've expired by now, but it looks like you didn't post the whole thing anyway.)
Hi there!
If you need more help you can view your support options (expected response time for a 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!