Skip to content

werkzeug.exceptions.BadRequest: 400 Bad Request: The browser (or proxy) sent a request that this server could not understand. #2525

Discussion options

You must be logged in to vote

How do you expect to get a JSON body when your request does not contain anything JSON-related? :)

https://flask.palletsprojects.com/en/2.2.x/api/#flask.Request.get_json

Try request.get_json(silent=True) instead.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by pradeepdev-1995
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #2524 on September 30, 2022 08:15.