cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
What’s new: end-to-end encryption, Replay and Dash updates. Find out more about these updates, new features and more 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: 

download file

download file

nisimy5
Explorer | Level 3

Hello,

I am trying to download a file and I always get "HTTP/1.1 400 Bad Request"

I am using in embedded app with wifi.

I did send the follows in buffer

"POST /2/files/download HTTP/1.1\r\n"
"Host: content.dropboxapi.com\r\n"
"Authorization: Bearer <my auth>\r\n"
"Dropbox-API-Arg: {\"path\": \"/FW_Upgrate.bin\"}\r\n"
"Content-Type: application/json\r\n"
"Content-Length: 0\r\n\r\n"

 

thanks,

Nisim

4 Replies 4

Greg-DB
Dropbox Staff

Please print out the response body. It should contain a more useful error message indicating what the issue it.

nisimy5
Explorer | Level 3

I get the following response:

HTTP/1.1 400 Bad Request
Server: nginx
Date: Wed, 26 Feb 2020 08:05:55 GMT
Content-Type: text/plain; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Content-Security-Policy: sandbox allow-forms allow-scripts
X-Dropbox-Request-I

Greg-DB
Dropbox Staff

That's just some of the response headers, but not the response body. Can you print out the response body too?

nisimy5
Explorer | Level 3
Thanks for your answer.
I did use in http instead of https.
Need more support?
Who's talking

Top contributors to this post

  • User avatar
    nisimy5 Explorer | Level 3
  • User avatar
    Greg-DB Dropbox Staff
What do Dropbox user levels mean?