The ASP.Net Web API is a framework that makes it easy to build REST Services that reach a broad range of clients, including browsers and mobile devices. It's an ideal platform for building Restful Services on the .NET Framework.
The following are the features of the ASP.Net WEB API:
- Strong support for URL Routing to produce clean URLs using familiar MVC style routing semantics
- Content Negotiation based on Accept headers for request and response serialization
- Support for a host of supported output formats including JSON, XML and ATOM
- ODATA Support
- Strong default support for REST semantics
- Very extensible, based on a MVC-like extensibility model of Formatters and Filters
- Self-hostable in non-web applications
- Testable using testing concepts similar to MVC
Demo
Let's create a database table using the following fields and insert some dummy data.
Now create project of the WEB API. I am using Visual Studio 2013 but you can also create it in Visual Studio 2012.
Once you create it look into the Controllers folder where you see ValuesController class that is the default. This class has all the default methods of the WEB API.

Create Entity Framework Class
Now write the repository class that will call the Entity Framework class and used for database interactions.

Call the Demo View from the Home Controller.
Now run the application.

rohit potdarPosted Jun 29, 2018, 2:54 AM
Edit Your post BCZ ...you are not shown how to add Empresponsitor then how beginer understanding
krishnakumar VCPosted Jan 7, 2017, 1:25 AM
Very helpful...............
Debendra DashPosted Jun 29, 2015, 7:59 AM
Good one...........
Pankaj BajajPosted Jun 29, 2015, 4:39 AM
Thanks Gopi..
Gopi ChandPosted Jun 29, 2015, 4:13 AM
Great work
Sibeesh VenuPosted Jun 29, 2015, 3:11 AM
Good one...