ASP.NET Core API for managing Pathfinder clubs, pathfinders, honors, achievements, and related status workflows. The solution targets .NET 10 and uses EF Core with PostgreSQL.
PathfinderHonorManager/: API project (controllers, services, EF Core, DTOs, validators, health checks).PathfinderHonorManager.Tests/: NUnit test project with in-memory EF helpers and controller/service tests.PathfinderHonorManager/Pathfinder-DB/: database scripts.EF_MIGRATIONS_README.md: migration workflow and baseline setup details.
- .NET SDK 10.0
- PostgreSQL (for local database work)
Set environment variables or user secrets as needed:
PathfinderCS(connection string)Auth0:DomainAuth0:AudienceAuth0:ClientId
Example local connection string:
Host=localhost;Database=pathfinder;Username=dbuser;Password=yourpassword
- Build:
dotnet build PathfinderHonorManager.sln - Run:
dotnet run --project PathfinderHonorManager - Test:
dotnet test PathfinderHonorManager.Tests/PathfinderHonorManager.Tests.csproj
This repo uses a baseline migration for existing databases. See EF_MIGRATIONS_README.md for the full workflow. Common commands:
- List migrations:
dotnet ef migrations list --project PathfinderHonorManager - Add migration:
dotnet ef migrations add DescriptiveMigrationName --project PathfinderHonorManager - Apply migration:
dotnet ef database update --project PathfinderHonorManager
/health/health/ready/health/live
- Tests use NUnit (
[Test],[TestCase]) and EF Core in-memory/SQLite helpers. - Validators use FluentValidation (
PathfinderHonorManager/Validators). - Swagger UI OAuth2 auth wiring is handled by a document filter (
PathfinderHonorManager/Swagger/AuthorizeCheckDocumentFilter.cs) to ensure secured endpoints declaresecurityrequirements under Swashbuckle v10/.NET 10. This only affects the generated OpenAPI document and Swagger UI behavior.