Support strict schema checking option to prevent parameter duplication
Is your feature request related to a problem? Please describe.
Currently, I'm able to duplicate fields in the schema multiple times and the value of the last field is taken into account and populated in a object.
"input": { "firstName": "Test", "lastName": "Surname1", "lastName": "Surname2", "lastName": "Surname3", "lastName": "Surname4", "lastName": "Surname5", }
Request such as this one is considered valid and the Surname5 value is passed in the lastName property.
Describe the solution you'd like The generator settings could have an option for strict schema checking, where repeated fields will be considered invalid.
Describe alternatives you've considered As an alternative there could be some specific annotation to achieve the same? Or way of marking fields.
I poked a bit around in this codebase, and it seems to me that processing input isn't within the scope of this project. Not an expert, could be wrong.
From a Java perspective, it would be a problem in graphql-java. I'm guessing there is a similar project for each supported language. This project only generates java interfaces for GraphQL, it doesn't actually process it.