I have a Web API controller POST method that behaves fine locally and on the testing server. If everything goes well it returns:
new HttpResponseMessage( Htt
OWIN
Since the host choice is not mentioned here, I just wanted to add that in case of OWIN you have to use syneptody's solution BUT not in Global.asax, as per this answer and my own tests.
You want to insert IncludeErrorDetailPolicy.Always in the Startup.cs file:
public void Configuration(IAppBuilder appBuilder)
{
HttpConfiguration Config = new HttpConfiguration();
Config.IncludeErrorDetailPolicy = IncludeErrorDetailPolicy.Always;
...
}