Swashbuckle.WebApi
Swashbuckle.WebApi copied to clipboard
Swagger UI not generating in azure .net core
Swagger UI is not creating in a .net core application when deployed in azure but it is working perfectly in local
I have added this in
ConfigureServices(IServiceCollection services) methode in startup.cs
services.AddSwaggerGen(c => { c.SwaggerDoc("v1", new Info { Version = "v1", Title = "API", Description = "API" }); });
and
app.UseSwagger(); app.UseSwaggerUI(c => { c.SwaggerEndpoint("/swagger/v1/swagger.json", "API"); c.RoutePrefix = "swagger"; });
in Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
I have the same issue, we have a project deploying to Azure Web App, the /swagger/index.html produces 'Not Found', any thoughts?
I have the same issue. Any workaround?
I had a similar problem. It turned out that the code was only in the development environment