I am wondering if there is a "basic" asp.net web api template. I only see one "web api" project and it brings out of bit of stuff in and not sure if all of it I need.
You can either:
1) Create a new MVC4 project > choose Web API template - but that, as you point out, brings in a lot of stuff, including Modernizer, jQuery, Knockout and so on
2) Create a new ASP.NET empty Web application and install Web API web host from Nuget:
PM> Install-Package Microsoft.AspNet.WebApi
You then end up with a very clean, basic project, including only the necessary DLLs.
3) If you want to self host Web API (not do an ASP.NET MVC4 project), you can create a new console application and install Web API self host from Nuget:
PM> Install-Package Microsoft.AspNet.WebApi.SelfHost
which is perfect for lightweight services, but obviously you don't host inside IIS anymore so there are additional release/deployment considerations. You can read more about self host here -> http://www.asp.net/web-api/overview/hosting-aspnet-web-api/self-host-a-web-api
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With