In regards to class and parameter name mappings... I'd expect that if I create a JSON Schema based on a class I have in a given language (C# for example), that openapi-generator (fka swagger-codegen) would preserve the parameter names when I generate a client or server in the same language. I understand that there is a "bring your own models" option, and that works for virtually all use cases.
However, I'm in an edge case where I am having to pick apart "deep" legacy objects and create "shallow" objects to expose to the API endpoints.
My tool-chain involves:
The problem I have is that (badly named legacy) parameters having lowercase letters as their first character are getting re-normalized to uppercase, breaking my on-the-fly object mapper (parameters not found).
See here for more info: https://github.com/swagger-api/swagger-codegen/issues/8447
What I suggest is simply adding an option like "normalize-names" [true|false] to allow for my use case (rather selfish, I know), but maybe useful to others since many real-world/enterprise projects are NOT greenfield. Thoughts?
The problem I have is that (badly named legacy) parameters having lowercase letters as their first character are getting re-normalized to uppercase, breaking my on-the-fly object mapper (parameters not found).
What about adding an option to let you choose the parameter naming? Something like the following:
Naming convention for the property: 'camelCase', 'PascalCase', 'snake_case' and 'original', which keeps the original name (Default: camelCase)
Though that is helpful, it won't help in my use case. All I need is something like
Preserves the property names set in specification file: true | false
Hi,
What is the status of this now ?
Thanks.
Most helpful comment
Though that is helpful, it won't help in my use case. All I need is something like