DEV Community

Manik
Manik

Posted on • Updated on

How to Web API .Net Core Basics to Advanced Part1

What is Web API.
API stands for Application Programming Interface, which in simple terms allows two applications to talk to each other.
Asp.net 5 webapi

ASP.NET Web API is Microsoft .Net framework for building HTTP services that can be accessed from any client such as browsers, desktop applications and mobile devices. ASP.NET Web API can be used to build both RESTful and SOAP services.

ASP.NET Web API Core ASP.NET Core is an open-source, cross-platform framework for building modern, cloud-based web apps and we can chose whatever platforms we want to build them on. We can build and run ASP.Net Core applications on Windows, macOS or Linux. Some of the benefits we get when working with ASP.Net core are:

  1. It is a cloud-ready.
  2. Comes with Built-in dependency injection.
  3. Very lightweight.
  4. High-performance and modular HTTP request pipeline.
  5. We can host ASP.Net Core applications on IIS, Nginx, Apache and Docker.

Let us build our first Web API in ASP.NET Core5
To build a project select create a new project.
Asp.net 5 webapi

Select ASP.NET Core Web API
Asp.net 5 webapi

Select where we want to save it.
Asp.net 5 webapi

For the last step, select additional information. I am leaving everything as default but in future series we will investigate other options.
Alt Text

Now build and compile your Web API and you should see your WeatherForecast Endpoint.
Asp.net 5 webapi

Part 2 How to Web API Core set up Database Context >>>

Discussion (0)