Now using NSwag to generate a openapi doc and provide a visual api explorer via swagger-ui

This commit is contained in:
Niggl1999 2020-06-04 09:06:59 +02:00
parent 0dd5e69e6c
commit f604147de9
1 changed files with 3 additions and 0 deletions

View File

@ -37,6 +37,7 @@ namespace ScrumTaskboard
.UseNpgsql("Host=nig.gl; Port=8543; Username=scrum; Database=taskboard; Password=c6gXud7YvBWp2sgxSgy4wRN")
.Options));
services.AddControllers();
services.AddOpenApiDocument();
}
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
@ -64,6 +65,8 @@ namespace ScrumTaskboard
{
endpoints.MapControllers();
});
app.UseOpenApi();
app.UseSwaggerUi3();
}
}
}