问题
I was tasked to install Swagger into Web API project.
Installed: most recent version of Swashbuckle from nuget. (Swashbuckle.Core.Net45 and Swashbuckle.Net45)
Customized: App_Start\SwaggerConfig.cs. I was able to customize (change styles, added logo, modified descriptions)..
Now we need to change from https://[your-url]/swagger to https://[your-url]/help
Please advise
回答1:
Change routePrefix
of SwaggerUIOptions
parameter, default is "swagger"
回答2:
How about following the documentation? In your case you could change the SwaggerConfig
to
httpConfiguration
.EnableSwaggerUi("help/{*assetPath}");
The documentation can then be found at https://[your-url]/help/index
来源:https://stackoverflow.com/questions/36944432/how-to-change-https-your-url-swagger-to-custom-in-swagger