I m setting up a WCF service and i want to implement SwaggerWCF for the documantation.
i configured like SwaggerWCF docs. But when i want to access doc as http://localhost/RegistrationService/api-docs, it redirects me to http://localhost/RegistrationService/api-docs/index.html?url=/RegistrationService/api-docs/swagger.json . and it is giving 404.0 error.
I added Swagger Attributes in my Model and methods.In the following I am sharing my configuration.
My app.config
<configSections>
<section name="swaggerwcf" type="SwaggerWcf.Configuration.SwaggerWcfSection, SwaggerWcf" />
</configSections>
<swaggerwcf>
<tags>
<tag name="LowPerformance" visible="false" />
</tags>
<settings>
<setting name="InfoDescription" value="Sample Service to test SwaggerWCF" />
<setting name="InfoVersion" value="0.0.1" />
<setting name="InfoTermsOfService" value="Terms of Service" />
<setting name="InfoTitle" value="SampleService" />
<setting name="InfoContactName" value="Abel Silva" />
<setting name="InfoContactUrl" value="http://github.com/abelsilva" />
<setting name="InfoContactEmail" value="[email protected]" />
<setting name="InfoLicenseUrl" value="https://github.com/abelsilva/SwaggerWCF/blob/master/LICENSE" />
<setting name="InfoLicenseName" value="Apache License" />
</settings>
</swaggerwcf>
Global Asax
protected void Application_Start(object sender, EventArgs e)
{
RouteTable.Routes.Add(new ServiceRoute("api-docs", new WebServiceHostFactory(), typeof(SwaggerWcfEndpoint)));
}
Why am i getting 404 error?