Skip to content

Backend API

The backend is the NexisOmni repository: a .NET 10 / C# 14 ASP.NET Core API on EF Core 10 and PostgreSQL. It serves both auth planes (see The API contract) and owns the central database plus every tenant database.

The authoritative backend documentation stays next to the code:

  • NexisOmni/docs/developer-guide.md - full local setup, the migration model, and testing.
  • NexisOmni/docs/adr/ - the architecture decision records. ADR-0014 / 0015 / 0016 define the auth, wire contract, and security model; ADR-0022 covers tenancy scaling.
  • NexisOmni/docs/ops/ - operational runbooks (tenant graduation, deploy).
  • Two EF contexts. The central database and each tenant database are separate contexts with separate migration histories and output folders. During development, new migrations are squashed into one InitialCreate and the dev database is recreated to apply them; migrations are only split at a production release.
  • ~800+ xUnit tests. PostgreSQL-backed integration tests use Testcontainers and skip automatically when Docker is not running.
  • The API serves its own OpenAPI at /openapi/v1.json (without needing PostgreSQL), which is the source the web client is generated from.
  • Health endpoints. /health is a bare liveness probe that the POS release build depends on; /health/ready additionally checks that the central database is reachable and migrated.