A modern task tracking API similar to Jira, Linear, and YouTrack, built with ASP.NET Core 8 following Clean Architecture principles.
- Clean Architecture - Domain, Application, Infrastructure, and API layers
- CQRS Pattern - Command Query Responsibility Segregation with MediatR
- PostgreSQL - Primary database with JSONB support for custom fields
- Redis - Distributed caching
- RabbitMQ - Message broker with MassTransit
- SignalR - Real-time notifications
- JWT Authentication - Secure API access with refresh tokens
- RBAC - Role-based access control (Owner, Admin, Member, Guest)
- Workflow Engine - Customizable task statuses with transitions
- Audit Log - Complete history of all task changes
- .NET 8 (LTS)
- Entity Framework Core 8 (Code First)
- MediatR 14 (CQRS)
- FluentValidation 12
- Serilog (Structured Logging)
- OpenTelemetry (Metrics and Tracing)
- Swagger/OpenAPI
- .NET 8 SDK
- Docker (for local infrastructure)
Start the local infrastructure using Docker Compose:
docker-compose up -dThis will start:
- PostgreSQL (port 5432)
- Redis (port 6379)
- RabbitMQ (ports 5672, 15672 for management)
- Seq (port 5341 for log viewing)
Create initial migration:
cd src/TaskTracker.Infrastructure
dotnet ef migrations add InitialCreate -s ../TaskTracker.ApiApply migrations:
cd src/TaskTracker.Api
dotnet ef database updatecd src/TaskTracker.Api
dotnet runThe API will be available at:
- Swagger UI: http://localhost:5000
- Health Check: http://localhost:5000/health
TaskTracker/
├── src/
│ ├── TaskTracker.Domain/ # Entities, Value Objects, Domain Events
│ ├── TaskTracker.Application/ # Use Cases, DTOs, CQRS Handlers
│ ├── TaskTracker.Infrastructure/ # EF Core, Repositories, External Services
│ └── TaskTracker.Api/ # Controllers, Middleware, Configuration
├── tests/
│ ├── TaskTracker.Tests.Unit/ # Unit Tests
│ └── TaskTracker.Tests.Integration/ # Integration Tests with Testcontainers
└── docker-compose.yml
POST /api/auth/register- Register new userPOST /api/auth/login- Login and get tokensPOST /api/auth/refresh- Refresh access tokenGET /api/auth/me- Get current user profile
GET /api/workspaces- List all workspacesGET /api/workspaces/{id}- Get workspace detailsPOST /api/workspaces- Create workspacePUT /api/workspaces/{id}- Update workspaceDELETE /api/workspaces/{id}- Delete workspaceGET /api/workspaces/{id}/members- List workspace members
GET /api/workspaces/{workspaceId}/projects- List projectsGET /api/workspaces/{workspaceId}/projects/{id}- Get project detailsPOST /api/workspaces/{workspaceId}/projects- Create projectGET /api/workspaces/{workspaceId}/projects/{id}/statuses- Get workflow statuses
GET /api/tasks- List tasks with filtering and paginationGET /api/tasks/{id}- Get task detailsPOST /api/tasks- Create taskPUT /api/tasks/{id}- Update taskPATCH /api/tasks/{id}/status- Change task statusPATCH /api/tasks/{id}/assign- Assign taskPATCH /api/tasks/{id}/priority- Change priority
dotnet test tests/TaskTracker.Tests.UnitIntegration tests use Testcontainers and require Docker:
dotnet test tests/TaskTracker.Tests.IntegrationKey configuration options in appsettings.json:
{
"ConnectionStrings": {
"DefaultConnection": "Host=localhost;Database=tasktracker;Username=postgres;Password=postgres",
"Redis": "localhost:6379"
},
"JwtSettings": {
"Secret": "your-secret-key",
"Issuer": "TaskTracker",
"Audience": "TaskTrackerClients",
"ExpiryMinutes": 60
},
"RabbitMQ": {
"Host": "localhost",
"Username": "guest",
"Password": "guest"
}
}Connect to /hubs/tasks for real-time updates. Available events:
TaskCreatedTaskUpdatedTaskStatusChangedTaskAssigned
MIT