Welcome to the navigation

Magna enim dolore nulla anim velit reprehenderit laborum, ut ex in non est dolor nisi duis sit eu dolor ut lorem elit, irure ea qui. Nisi anim velit cillum ut cupidatat dolore qui do labore est fugiat ea amet, proident, ipsum mollit minim culpa excepteur quis incididunt magna voluptate dolore

Yeah, this will be replaced... But please enjoy the search!

Creating your custom HttpControllerContext for Web API

I needed to fiddle a bit in a API method returning a HttpResponseMessage when validating captchas that wasn't included in the model validation.

HttpConfiguration config = new HttpConfiguration();
IHttpRouteData route = new HttpRouteData(new HttpRoute());
HttpRequestMessage req = new HttpRequestMessage();
req.Properties[HttpPropertyKeys.HttpConfigurationKey] = config;
req.Properties[HttpPropertyKeys.HttpRouteDataKey] = route;
HttpControllerContext context = new HttpControllerContext(config, route, req);