We are aware of the issue with the badge emails resending to everyone, we apologise for the inconvenience - learn more here.
Forum Discussion
VijayKumar E
3 years agoExplorer | Level 3
Bad HTTP "Content-Type" header from the Dropbox API
When I try a request to Dropbox API(v2), I am getting this error ,
"message": "Error in call to API function "users/get_current_account": Bad HTTP "Content-Type\" header: "application/x-www-fo...
VijayKumar E
Explorer | Level 3
Hi ,
For the mentioned APIs '/users/get_space_usage' and '/users/get_current_account' I am not sending any data in the request. So why should I set the content-type as application/json", "application/json; charset=utf-8", "text/plain; charset=dropbox-cors-hack" for the request ?
In both cases we are just passing the authentication information by referring DropBox Documentation .
By seeing the error message I tried the APIs by setting those content-type as application/json", "application/json; charset=utf-8", "text/plain; charset=dropbox-cors-hack" but still it was not working .
When I tried the API by passing the content-type as empty string ( Content-Type : “” ) it’s working fine.
Здравко
3 years agoLegendary | Level 20
VijayKumar E wrote:... So why should I set the content-type as application/json", "application/json; charset=utf-8", "text/plain; charset=dropbox-cors-hack" for the request ? ....
You shouldn't set anything, actually.
VijayKumar E wrote:...
When I tried the API by passing the content-type as empty string ( Content-Type : “” ) it’s working fine.
Great! 👍 Seems you have found it. Maybe that's the way in your environment to disable content-type header sending together with empty query body. 🤷
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
5,877 PostsLatest Activity: 9 hours agoIf 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 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!