[英]Swagger UI Not Accessible in ASP.NET 4.5 Application
I have an ASP.NET 4.5 web api application for the backend with an AngularJS 1.5.4 frontend and have added the swashbuckle package. I have an ASP.NET 4.5 web api application for the backend with an AngularJS 1.5.4 frontend and have added the swashbuckle package. When I go to localhost:9000/swagger I get redirected to my login page.
当我 go 到 localhost:9000/swagger 时,我被重定向到我的登录页面。
I'm not too sure where my problem is coming from so I don't know what information to include.我不太确定我的问题来自哪里,所以我不知道要包含哪些信息。
What could potentially fix my issue of not being able to access the swagger/ui/index page?什么可以解决我无法访问 swagger/ui/index 页面的问题?
This fixed the issue for me, I added this rule to the Web.config file.这解决了我的问题,我将此规则添加到 Web.config 文件中。
<rule name="Swagger" enabled="true" stopProcessing="true">
<match url="swagger" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="None" />
</rule>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.