title: AJAX call can't find my WebAPI Controller
body: <p>I have the following AJAX call:</p>
  
  <pre><code>var params = {
      provider: "facebook"
  };
  
  $.ajax({
      url: "http://localhost/taskpro/api/account/ExternalLogin",
      data: JSON.stringify(params),
      type: "POST",
      contentType: 'application/json; charset=utf-8'
  })
  .done(function (response) {
      alert("Success");
  });
  </code></pre>
  
  <p>calling the following WebAPI controller:</p>
  
  <pre><code>public class AccountController : ApiController
  {
      [HttpPost]
      [AllowAnonymous]
      public bool ExternalLogin(string provider)
      {
          return true;
      }
  }
  </code></pre>
  
  <p>with the following routemap:</p>
  
  <pre><code>config.Routes.MapHttpRoute(
      name: "DefaultApi",
      routeTemplate: "api/{controller}/{action}/{id}",
      defaults: new { id = RouteParameter.Optional }
  );
  </code></pre>
  
  <p>When I execute this, fiddler is returning:</p>
  
  <pre><code>{"Message":"No HTTP resource was found that matches the request URI 
  'http://localhost/taskpro/api/account/ExternalLogin'.","MessageDetail":
  "No action was found on the controller 'Account' that matches the request."}
  </code></pre>
  
  <p>I have several other calls being made to this controller that are working just fine.  It's just THIS call that is giving me troubles.</p>
  
  <p>Also, if I remove the parameter in the controller so it's just </p>
  
  <pre><code>public bool ExternalLogin()
  </code></pre>
  
  <p>and comment out the data line in the ajax, it works fine.</p>
  
  <p>Any ideas why the routing is not working for this call?</p>