I have two different controllers and each one with its configured routes. To explain my problem, I will exemplify:
ProdutoController
[Route("v1/empresas/{idConexao}/produtos/{id}")]
ProdutoCategoriaController
[Route("v1/empresas/{idConexao}/produtos/categorias")]
When doing a GET on the route "v1/empresas/{idConexao}/produtos/categorias" using postman I get the following error message:
Multiple controller types were found that match the URL. This can happen if attribute routes on multiple controllers match the requested URL
But if I comment on route "v1/empresas/{idConexao}/produtos/{id}" I can do a get on route "v1/empresas/{idConexao}/produtos/categorias" and vice versa.
Does anyone know how i can solve this problem? I see no sense in this error