Things you didn't know about action return types in ASP.NET Web API - StrathWeb

added by Paul Wheeler
9/15/2014 5:34:19 PM


When you are developing an ASP.NET Web API application, you can chose whether you want to return a POCO from your action, which can be any type that will then be serialized, an instance of HttpResponseMessage, or, since Web API 2, an instance of IHttpActionResult. Let’s have a look at what really happens under the hood afterwards, and discuss some of the things about the response pipeline that you might have not known before.