Asp.net web api Web API REST请求上未找到OWin启动属性错误

Asp.net web api Web API REST请求上未找到OWin启动属性错误,asp.net-web-api,asp.net-web-api2,owin,Asp.net Web Api,Asp.net Web Api2,Owin,我有一个Web API项目以及内置的帮助网站。当我在本地启动项目时,帮助网站主页显示没有问题。但是,当我使用fiddler向API控制器发送REST POST请求时,我得到以下响应 The following errors occurred while attempting to load the app. - No assembly found containing an OwinStartupAttribute. - No assembly found containing a Star

我有一个Web API项目以及内置的帮助网站。当我在本地启动项目时,帮助网站主页显示没有问题。但是,当我使用fiddler向API控制器发送REST POST请求时,我得到以下响应

The following errors occurred while attempting to load the app.
 - No assembly found containing an OwinStartupAttribute.
 - No assembly found containing a Startup or [AssemblyName].Startup class.
To disable OWIN startup discovery, add the appSetting owin:AutomaticAppStartup with a value of "false" in your web.config.
To specify the OWIN startup Assembly, Class, or Method, add the appSetting owin:AppStartup with the fully qualified startup class or configuration method name in your web.config.
我尝试使用错误消息中的建议来解决问题,但没有任何乐趣

它在测试服务器上正常工作


有人能提出为什么只有在REST请求时才返回此错误,而不是在帮助网站启动时返回此错误,以及如何解决此问题的提示吗?

您是否有启动课程?如果没有-检查这篇文章是的,我有一个这样的类-虽然我不知道为什么它仍然在寻找它,因为我在web.config设置。当帮助网站运行时,startupo类确实会受到攻击,但不是在REST请求下。您是否混合了Wep API和MVC?可能您需要从MVC中排除Web API路由。(这只是考虑因素,但我对拥有WCF服务的MVC站点也有同样的问题)