diff --git a/src/Backend/VanDaemon.Api/Program.cs b/src/Backend/VanDaemon.Api/Program.cs index c6cc218..1f4e2bc 100644 --- a/src/Backend/VanDaemon.Api/Program.cs +++ b/src/Backend/VanDaemon.Api/Program.cs @@ -73,11 +73,13 @@ } // Configure the HTTP request pipeline -if (app.Environment.IsDevelopment()) +// Enable Swagger in all environments for API documentation access +app.UseSwagger(); +app.UseSwaggerUI(c => { - app.UseSwagger(); - app.UseSwaggerUI(); -} + c.SwaggerEndpoint("/swagger/v1/swagger.json", "VanDaemon API v1"); + c.RoutePrefix = "swagger"; // Explicitly set the route prefix +}); app.UseCors("AllowAll"); app.UseAuthorization();