Compare commits

...

7 Commits

Author SHA1 Message Date
b6000a56d6 Add ActionController and Swagger support
Updated `ReC.API.csproj` to include `Swashbuckle.AspNetCore` (v6.6.2) for Swagger/OpenAPI documentation. Removed an unused `<ItemGroup>` referencing the `Controllers\` folder.

Added a new `ActionController` with a `[Route("api/[controller]")]` and `[ApiController]` attributes. Introduced a `Trigger` HTTP POST endpoint that accepts a `profileId` parameter. The method is currently unimplemented and throws a `NotImplementedException`.
2025-11-25 00:47:00 +01:00
3f5d3a8c08 Add new ReC.Client project to solution
A new project, ReC.Client, has been added to the solution file (ReC.sln).
The project supports two target frameworks: net462 and net8.0.
Build configurations for Debug and Release have been added, and the
project has been nested under the same parent as other projects.

The ReC.Client.csproj file uses the Microsoft.NET.Sdk SDK and includes
conditional properties for frameworks other than net462, enabling
implicit global usings and nullable reference types.
2025-11-25 00:40:59 +01:00
72e4f53b5d Add ReC.Application project to the solution
A new project, `ReC.Application`, has been added to the solution (`ReC.sln`).
The project file (`ReC.Application.csproj`) targets .NET 8.0, enables implicit
global usings, and enables nullable reference types.

The solution file has been updated to include the new project, its build
configurations, and its nesting under the `src` folder.
2025-11-25 00:36:34 +01:00
f35e29ae49 Add ReC.Infrastructure project to the solution
A new project, `ReC.Infrastructure`, has been added to the solution.
The project is configured to target `.NET 8.0` and includes modern
features such as implicit global usings and nullable reference types.
It has been integrated into the solution's build configurations
(Debug/Release for Any CPU) and nested under the `src` folder.
2025-11-25 00:31:34 +01:00
cb1b02196c Add ReC.Domain project to solution
A new project, `ReC.Domain`, has been added to the solution.
The project is included in `ReC.sln` with build configurations
for `Debug|Any CPU` and `Release|Any CPU`. It is nested under
the `src` folder in the solution structure.

The `ReC.Domain.csproj` file targets .NET 8.0, uses the
`Microsoft.NET.Sdk` SDK, and enables modern C# features such
as implicit `using` directives and nullable reference types.
2025-11-25 00:30:24 +01:00
9de7b89a81 Set up ASP.NET Core Web API project structure
Initialized the ASP.NET Core application in `Program.cs` with
services for controllers, Swagger/OpenAPI, and middleware
for HTTPS redirection and authorization.

Added `launchSettings.json` to configure application launch
profiles for HTTP, HTTPS, and IIS Express environments.

Updated `ReC.API.csproj` to target .NET 8.0, enable nullable
reference types, and include the `Swashbuckle.AspNetCore`
package for Swagger support.

Added `appsettings.json` and `appsettings.Development.json`
for logging and environment-specific configurations.

Reorganized the solution structure in `ReC.sln` by moving
the `ReC.API` project under a `src` folder and updating
the `NestedProjects` section.
2025-11-25 00:28:46 +01:00
a2f11a7083 Initialize ASP.NET Core Web API project
Set up a new ASP.NET Core Web API project named `ReC.API` targeting .NET 8.0.

- Added `ReC.sln` solution file with Debug and Release configurations.
- Configured logging settings in `appsettings.json` and `appsettings.Development.json`.
- Created `Program.cs` to bootstrap the application with controllers, Swagger, and middleware.
- Defined project structure in `ReC.API.csproj`, including Swagger dependency and nullable reference types.
- Added `launchSettings.json` with profiles for `http`, `https`, and `IIS Express`.
2025-11-25 00:25:51 +01:00
11 changed files with 207 additions and 0 deletions

58
ReC.sln Normal file
View File

@ -0,0 +1,58 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.14.36717.8
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ReC.API", "src\ReC.API\ReC.API.csproj", "{420218AD-3C27-4003-9A84-36C92352F175}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{02EA681E-C7D8-13C7-8484-4AC65E1B71E8}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ReC.Domain", "src\ReC.Domain\ReC.Domain.csproj", "{2917BEA4-6C70-40CD-BD46-57D4ADB40296}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ReC.Infrastructure", "src\ReC.Infrastructure\ReC.Infrastructure.csproj", "{587A4D14-EFDA-4BE3-8912-D3AF84743079}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ReC.Application", "src\ReC.Application\ReC.Application.csproj", "{109645F5-441D-476B-B7D2-FBEAA8EBAE14}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ReC.Client", "src\ReC.Client\ReC.Client.csproj", "{DA3A6BDD-8045-478F-860B-D1F0EB97F02B}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{420218AD-3C27-4003-9A84-36C92352F175}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{420218AD-3C27-4003-9A84-36C92352F175}.Debug|Any CPU.Build.0 = Debug|Any CPU
{420218AD-3C27-4003-9A84-36C92352F175}.Release|Any CPU.ActiveCfg = Release|Any CPU
{420218AD-3C27-4003-9A84-36C92352F175}.Release|Any CPU.Build.0 = Release|Any CPU
{2917BEA4-6C70-40CD-BD46-57D4ADB40296}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{2917BEA4-6C70-40CD-BD46-57D4ADB40296}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2917BEA4-6C70-40CD-BD46-57D4ADB40296}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2917BEA4-6C70-40CD-BD46-57D4ADB40296}.Release|Any CPU.Build.0 = Release|Any CPU
{587A4D14-EFDA-4BE3-8912-D3AF84743079}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{587A4D14-EFDA-4BE3-8912-D3AF84743079}.Debug|Any CPU.Build.0 = Debug|Any CPU
{587A4D14-EFDA-4BE3-8912-D3AF84743079}.Release|Any CPU.ActiveCfg = Release|Any CPU
{587A4D14-EFDA-4BE3-8912-D3AF84743079}.Release|Any CPU.Build.0 = Release|Any CPU
{109645F5-441D-476B-B7D2-FBEAA8EBAE14}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{109645F5-441D-476B-B7D2-FBEAA8EBAE14}.Debug|Any CPU.Build.0 = Debug|Any CPU
{109645F5-441D-476B-B7D2-FBEAA8EBAE14}.Release|Any CPU.ActiveCfg = Release|Any CPU
{109645F5-441D-476B-B7D2-FBEAA8EBAE14}.Release|Any CPU.Build.0 = Release|Any CPU
{DA3A6BDD-8045-478F-860B-D1F0EB97F02B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DA3A6BDD-8045-478F-860B-D1F0EB97F02B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DA3A6BDD-8045-478F-860B-D1F0EB97F02B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DA3A6BDD-8045-478F-860B-D1F0EB97F02B}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{420218AD-3C27-4003-9A84-36C92352F175} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8}
{2917BEA4-6C70-40CD-BD46-57D4ADB40296} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8}
{587A4D14-EFDA-4BE3-8912-D3AF84743079} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8}
{109645F5-441D-476B-B7D2-FBEAA8EBAE14} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8}
{DA3A6BDD-8045-478F-860B-D1F0EB97F02B} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {F7B09104-4072-4635-9492-9C7C68D96ABD}
EndGlobalSection
EndGlobal

View File

@ -0,0 +1,15 @@
using Microsoft.AspNetCore.Mvc;
namespace ReC.API.Controllers;
[Route("api/[controller]")]
[ApiController]
public class ActionController : ControllerBase
{
[HttpPost("{profileId}")]
public Task<IActionResult> Trigger([FromRoute] int profileId)
{
// Implementation for retrieving actions would go here.
throw new NotImplementedException();
}
}

25
src/ReC.API/Program.cs Normal file
View File

@ -0,0 +1,25 @@
var builder = WebApplication.CreateBuilder(args);
// Add services to the container.
builder.Services.AddControllers();
// Learn more about configuring Swagger/OpenAPI at https://aka.ms/aspnetcore/swashbuckle
builder.Services.AddEndpointsApiExplorer();
builder.Services.AddSwaggerGen();
var app = builder.Build();
// Configure the HTTP request pipeline.
if (app.Environment.IsDevelopment())
{
app.UseSwagger();
app.UseSwaggerUI();
}
app.UseHttpsRedirection();
app.UseAuthorization();
app.MapControllers();
app.Run();

View File

@ -0,0 +1,41 @@
{
"$schema": "http://json.schemastore.org/launchsettings.json",
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "http://localhost:9130",
"sslPort": 44366
}
},
"profiles": {
"http": {
"commandName": "Project",
"dotnetRunMessages": true,
"launchBrowser": true,
"launchUrl": "swagger",
"applicationUrl": "http://localhost:5055",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"https": {
"commandName": "Project",
"dotnetRunMessages": true,
"launchBrowser": true,
"launchUrl": "swagger",
"applicationUrl": "https://localhost:7184;http://localhost:5055",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"IIS Express": {
"commandName": "IISExpress",
"launchBrowser": true,
"launchUrl": "swagger",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
}
}
}

View File

@ -0,0 +1,13 @@
<Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.6.2" />
</ItemGroup>
</Project>

View File

@ -0,0 +1,8 @@
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
}
}

View File

@ -0,0 +1,9 @@
{
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
},
"AllowedHosts": "*"
}

View File

@ -0,0 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,11 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>net462;net8.0</TargetFrameworks>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' != 'net462'">
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
</Project>