Closed rsanhuez closed 4 years ago
Hi,
try to remove the next block of code:
opt.DownstreamSwaggerEndPointBasePath = "/gateway/swagger/docs";
opt.PathToSwaggerGenerator = "/swagger/doc";
use only app.UseSwaggerForOcelotUI(Configuration)
you can try new prerelease version 2.0.0-alpha.4
It worked perfectly. Thanks!. Now I am going to add some custom controllers to the API Gateway and see If I am able to display them along with the Ocelot's endpoints.
I am glad to hear that.
Hi. I am testing this package to use it in a project. I tried to follow the steps of the README and the example on https://github.com/Burgyn/MMLib.SwaggerForOcelot/tree/master/demo/ApiGatewayWithPath. For testing purposes I am connecting one API Gateway with one Microservice. The technologies used are:
When I try to display the swagger documentation of my Microservice (http://localhost:8888/swagger/v1/swagger.json) through my API Gateway (http://localhost:7777/gateway/swagger/index.html) I get the following error:
And in Visual Studio:
Any help to solve this problem would be very appreciated. Note that Ocelot itself is working fine. For example I get the correct response from the API Gateway using this URL on the web browser: http://localhost:7777/api/transacciones/EstadoSolicitud
My simple ocelot.json is the following:
My Program.cs:
And my Startup.cs: