hope you doing great !
I am working currently on a bff (Back for frontend) project with ASP.Net Core, that consumes an external api. For simplicity purposes, we used **Nswag **which is a tool to generate code from an api specification compliant to the OpenApi Specification. It generates for me, date models in addition to methods for requesting each ressource of the api.
While testing my first Controller for the project, i relalized that the request body i am sending contains a new property "ValueKind" that i didn't send initialy, and that was added after the deserialization of the request body.
You ll find attatched to this description, examples of the data model of the request body, and the body i am recieving in the controller.
Has anyone run into the same problem before ?
The request when sent :
{ "someProperty": {} }
The request i get in the controller :
{ "SomeProperty": { "ValueKind": 3 } }