Initial .NET API service

This commit is contained in:
AppFactory Bot
2026-06-12 10:26:56 +00:00
commit bbec747bb7
6 changed files with 60 additions and 0 deletions
+22
View File
@@ -0,0 +1,22 @@
var builder = WebApplication.CreateBuilder(args);
var app = builder.Build();
var rootPath = Environment.GetEnvironmentVariable("ROOT_PATH");
if (!string.IsNullOrWhiteSpace(rootPath))
{
app.UsePathBase(rootPath);
}
app.MapGet("/", () => Results.Json(new
{
name = "iDoklad",
service = "idoklad",
status = "ok"
}));
app.MapGet("/health", () => Results.Json(new
{
status = "ok"
}));
app.Run();