Tech Junkie Blog - Real World Tutorials, Happy Coding!: ACMEBank: Step 4: Create An Asp.Net Core Web API With The Asp.Net Core CLI

Tuesday, September 1, 2020

ACMEBank: Step 4: Create An Asp.Net Core Web API With The Asp.Net Core CLI

 In this post we are going to use the .NET Core CLI to create a web api application for our app.  The first thing to do is create an a folder to hold our files.  Since we are using Linux you want to sudo su into the terminal and create the following folder /opt/app/ACMEBank.  Once that's done cd into it and you are ready to type in the command to create the Web Api.

Here are the steps:

1. What you want to do first is to make sure that you have .NET Core install by typing in dotnet --info, there should be information on your .NET Core install.  If you don't have .NET install you can follow the directions in this post.

2. Now we are ready to create the Web Api, type dotnet new webapi -n ACMEBank.API in the terminal.  Here is a breakdown of the command

  • new - create a new .NET project
  • webapi - create new Web Api project
  • -n - name option for the name of the project

3.  Once the creation of the Web Api project is finished, type code . , make sure you are not a super user before you type code . , else VSCode won't open


4. Web Api in VSCode

You've just create a new Web Api project for our ACME Bank application.


3 comments:

  1. Everything is very open with a very clear description of the challenges. It was really informative. Your website is extremely helpful. Thank you for sharing!

    No more waste time to searching #HDimages, #PCwallpaper, #smartphone_wallpaper, #socialmedia_banner, #socialmedia_image_post, #natureHDimages, and many more awesome pictures. Just visit All Awesome Pictures Only For Love Hearts and choose your best choice.

    ReplyDelete

Search This Blog