This is a basic minimal API service that hosts Authentication/Identity using JWTs in C# .NET 10. This API has a register and login endpoint (see AuthenticationEndpoints.cs) that allows a user to register with just a username and password.
This service uses postgreSQL to persist user information. This can be changed to whatever connection you need by changing line 10 in Program.cs. The current connection string is located in appsettings.json and appsettings.Development.json - change the connection string to match where your DB is located. By default, this uses a DB called BasicAuthServer, but this DB name and its password in the DefaultConnection string should be changed to match your setup.
This service is nice too in that any .NET Entity Framework migrations you have created will automatically apply those Migrations when the service starts up (see line 45 of Program.cs). You only need to make a migration using "dotnet ef migrations add YourUpdateName" and then any changes to the AppDbContext.cs will be applied.