Hi @Jassim Al Rahma ,
Your scenario can be achieved using either an API App or a Web API. Both options are valid and can be used to create a RESTful web service.
Here are the steps to create a RESTful web app using an API App:
- Open Visual Studio for Mac and create a new project.
- Select "Cloud" from the left-hand menu and then select "Azure API App" from the list of project templates.
- Follow the prompts to configure your API App project. You will need to provide a name for your project, select a subscription and resource group, and choose a hosting plan.
- Once your project is created, you can add your RESTful endpoints to the project. You can do this by adding a new controller class to your project and defining your endpoints using the
[HttpGet]
, [HttpPost]
, [HttpPut]
, and [HttpDelete]
attributes.
- Deploy your API App to Azure by right-clicking on your project in Visual Studio for Mac and selecting "Publish". Follow the prompts to configure your deployment settings and publish your app to Azure.
Here are the steps to create a RESTful web service using a Web API:
- Open Visual Studio for Mac and create a new project.
- Select "Web" from the left-hand menu and then select "ASP.NET Core Web Application" from the list of project templates.
- Follow the prompts to configure your Web API project. You will need to provide a name for your project, select a template (such as "API"), and choose a hosting option.
- Once your project is created, you can add your RESTful endpoints to the project. You can do this by adding a new controller class to your project and defining your endpoints using the
[HttpGet]
, [HttpPost]
, [HttpPut]
, and [HttpDelete]
attributes.
- Deploy your Web API to Azure by right-clicking on your project in Visual Studio for Mac and selecting "Publish". Follow the prompts to configure your deployment settings and publish your app to Azure.
Hope this helps. Let us know if you have any questions.
-Grace