Articles
19
I spent a fruitless evening trying to track down why my get request returned the badrequest result.

Using FastEndpoints under net 9.

Discovered that a get, with the content-type header application/json, seems to cause this problem. I conjecture that it's because gets normally have no body. I suspect the FastEndpoints code tries to deserialize an empty body as JSON. This results in a JSON parsing error; returned to the client as a bad request.

Removing the content type header fixed the problem for me.

Comments

There are currently no comments, be the first to post one!

Post Comment

Only registered users may post comments.
Copyright 2002-15 by Dynamisys Ltd