title: Specific JSON settings per controller on ASP.NET MVC 6
body: <p>I need specific JSON settings per controller in my ASP.NET MVC 6 webApi.
  I found this sample that works (I hope !) for MVC 5 : 
  <a href="https://stackoverflow.com/questions/19956838/force-camalcase-on-asp-net-webapi-per-controller">Force CamelCase on ASP.NET WebAPI Per Controller</a></p>
  
  <pre><code>using System;
  using System.Linq;
  using System.Web.Http.Controllers;
  using System.Net.Http.Formatting;
  using Newtonsoft.Json.Serialization;
  
  public class CamelCaseControllerConfigAttribute : Attribute, IControllerConfiguration 
  {
      public void Initialize(HttpControllerSettings controllerSettings, HttpControllerDescriptor controllerDescriptor)
      {
          var formatter = controllerSettings.Formatters.OfType&lt;JsonMediaTypeFormatter&gt;().Single();
          controllerSettings.Formatters.Remove(formatter);
  
          formatter = new JsonMediaTypeFormatter
          {
              SerializerSettings = {ContractResolver = new CamelCasePropertyNamesContractResolver()}
          };
  
          controllerSettings.Formatters.Add(formatter);
  
      }
  }
  </code></pre>