title: API 2 Controller not working in ASP.NET MVC 5
body: <p>I'm not sure why but my api route just isn't working? What I do is click on the add controller, select Web API 2 controller with actions using EF (so that it builds it for me) select the model and context and click Add.</p>
  
  <p><strong>WebApiConfig</strong></p>
  
  <pre><code>public static void Register(HttpConfiguration config)
      {
          config.MapHttpAttributeRoutes();
  
          config.Routes.MapHttpRoute(
              name: "DefaultApi",
              routeTemplate: "api/{controller}/{id}",
              defaults: new { id = RouteParameter.Optional }
          );
      }
  </code></pre>
  
  <p><strong>ProductsController (ApiController)</strong></p>
  
  <pre><code>public IQueryable&lt;Product&gt; GetProducts()
      {
          return db.Products;
      }
  </code></pre>
  
  <p>This would imply that by going to /api/products it would display a json format of products ... it doesn't. What I DO get is a 404: The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. I tried putting a breakpoint in too and that doesn't even get hit. So I'm a little confused.</p>
  
  <p>I do have custom Web Route configs, which I thought could have been the problem, but when commenting them out still this happens. Is scaffolding missing something?</p>
  
  <p>Thanks for any help</p>