Skip to content
/ ToDoAppTemplate Public template

ToDo API template with authentication using .NET8 with CQRS and REPR patterns

License

Notifications You must be signed in to change notification settings

Loupeznik/ToDoAppTemplate

Repository files navigation

ToDo app template API

A template repository for a ToDo app API with .NET8 and PostgreSQL. REPR (FastEndpoints), CQRS (MediatR) and partially Clean Architecture patterns are used. The API is easily extensible and can be used as a starting point for a new project.

Functionality:

  • Create, read, update and delete ToDos
  • User registration, login, option to reset user's password. Accounts are stored in the database, authentication is done using JWT.
  • Email templates and sending emails via Smtp or SendGrid is supported. Email templates are written in Liquid templating language.

Prerequisites

Applying the database migrations

The database migrations are located in the ToDoAppTemplate.Data project. The following commands can be run from the solution root directory:

# Create a new migration
dotnet ef migrations add MigrationName --project ./ToDoAppTemplate.Data --startup-project ./ToDoAppTemplate.Api
# Apply a migration
dotnet ef database update --project ./ToDoAppTemplate.Data --startup-project ./ToDoAppTemplate.Api

Running the API

Either run the API by running docker-compose up from the root of the solution. This will start the API and a PostgreSQL database in Docker containers.

Or run the API from Visual Studio or the command line. The connection string to the database can be configured in the appsettings.json file.

About

ToDo API template with authentication using .NET8 with CQRS and REPR patterns

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published