From b583e866315289cb7d8991955df2716bec1dc417 Mon Sep 17 00:00:00 2001 From: Lucas Morgan Date: Sun, 25 Aug 2024 14:05:43 -0500 Subject: [PATCH] debugging relative swagger-ui routing --- Shogi.Api/Program.cs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Shogi.Api/Program.cs b/Shogi.Api/Program.cs index 05a587e..22b5d6f 100644 --- a/Shogi.Api/Program.cs +++ b/Shogi.Api/Program.cs @@ -46,8 +46,15 @@ else { app.UseResponseCompression(); } -app.UseSwagger(); -app.UseSwaggerUI(options => options.DocumentTitle = "Shogi.Api"); +app.UseSwagger(options => +{ +}); +app.UseSwaggerUI(options => +{ + options.RoutePrefix = "swagger"; + options.SwaggerEndpoint("v1/swagger.json", "My API V1"); + options.DocumentTitle = "Shogi.Api"; +}); app.UseAuthorization(); app.Map("/", () => "OK"); app.MapControllers();