I am working on a project written in French. The classes are named in French. I want to use code generation for a C# client.
[Route("[controller]s")]
public class EtablissementControleur : ControllerBase
{
...
}
My api route is good and my swagger documentation is good, because I took care of the translation.
/api/v1/etablissements/{id}/adresse
Here is the partial configuration of the generator
nswag.json
"codeGenerators": {
"openApiToCSharpClient": {
"className": "{controller}HttpService",
...
The name of the generated service is EtablissementControleurHttpService, whereas I was expecting EtablissementHttpService.
[System.CodeDom.Compiler.GeneratedCode("NSwag", "13.18.0.0 (NJsonSchema v10.8.0.0 (Newtonsoft.Json v13.0.0.0))")]
public partial class EtablissementControleurHttpService : IEtablissementControleurHttpService
{
Should I tell the generator to remove the word Controller? Or should I modify the swagger documentation to support it? Thanks for your help