cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements
Update: Find information on Dropbox support during COVID-19 here
Close
cancel
Showing results for 
Search instead for 
Did you mean: 

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

Re: download file

Dropboxer
Dropboxer

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

Re: download file

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

Re: download file

Dropboxer
Dropboxer

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

Re: download file

nisimy5
Explorer | Level 3
Thanks for your answer.
I did use in http instead of https.

Work Smarter with Dropbox

The way we work is changing. Share and discover new ways to work smarter with Dropbox in our community.

Sound good? Let's get started.
Who's talking

Top contributors to this post

What do Dropbox user levels mean?
Need more support?