Welcome to the navigation

Aliquip mollit veniam, aute proident, occaecat anim voluptate incididunt dolor excepteur eiusmod aliqua, eu laborum, cupidatat cillum nulla ullamco dolor laboris in dolore sunt nostrud. Excepteur incididunt irure et commodo enim reprehenderit deserunt magna ex laboris do dolor cupidatat est esse eiusmod veniam, officia aute adipisicing occaecat voluptate ut velit

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);