Routing in Web API

If you have worked with MVC routing, you will find out that there are lots of similarities with web API and actually Web API uses the MVC standards on routing. There is only one difference and that's about using HTTP method in web API instead of URL path in MVC. In other word, Web API does not specify an action route parameter, bur it by default maps incoming requests to the appropriate action based upon the HTTP verb of the request.

Take a look at the following sample: 

  1. [HttpPut]
  2. public HttpResponseMessage Order... Continue