Need to see if your shared folder is taking up space on your dropbox đšâđ»? Find out how to check here.
Forum Discussion
Shilpa M.
10 years agoNew member | Level 1
Not getting response when I call "2/files/listfolder" method
Hi
I passed "https://api.dropboxapi.com/2/files/list_folder" to fetch files and folder from root.
and Passed parameters are:-
string path=string.empty;
request.AddHeader("Content-Type","appli...
Shilpa M.
10 years agoNew member | Level 1
I have try different approaches to upload a new file but every time i got same error every time.
Error in call to API function "files/upload": Bad HTTP "Content-Type" header: "application/octet-stream;". Expecting one of "application/octet-stream", "text/plain; charset=dropbox-cors-hack".
my code is
string fullPathToUpload = metadataJson.path + "/" + externalFile.Name;
string path = string.Format("{1}\"path\":\"{0}\"{2}", fullPathToUpload, "{", "}");
request.AddHeader("Dropbox-API-Arg", path);
request.AddHeader("Content-Type","application/octet-stream;");
// externalFile.ContentType = "application/octet-stream";
//request.AddFile("file", externalFile.FileBody, externalFile.Name);//File body in byes Array
request.AddObject(externalFile.FileBody, "data"); request.AddHeader("Authorization", "Bearer " + accessToken);
return client.Execute(request);
Please suggest.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
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, Facebook or Instagram.
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!