dotnet-expert

Design .NET backend architecture with ASP.NET Core, EF Core 9, and MediatR CQRS.

Updated Feb 26, 2026
One-click install
npx skills add https://github.com/gabi-agent/openretro --skill dotnet-expert-gabi-agent
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dotnet-expert
Source: https://github.com/gabi-agent/openretro/tree/main/skills/dotnet-expert
Command: npx skills add https://github.com/gabi-agent/openretro --skill dotnet-expert-gabi-agent

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Design and implement robust .NET backends by applying clean architecture principles, CQRS with MediatR, modular monolith patterns, and FluentValidation for reliable input validation.

Core Features & Use Cases

  • Feature-based modular structure that organizes code by domain (Users, Orders, Shared) rather than by technical layers.
  • Result pattern for business logic to return success or structured errors instead of throwing exceptions.
  • MediatR-based CQRS with a validation pipeline to decouple commands/queries from handlers and enforce input validation.
  • ASP.NET Core APIs, EF Core 9, and JWT authentication for secure, scalable data access.
  • Strong typing, auditing, and query optimization support for production-grade APIs.

Quick Start

Configure a production-ready .NET backend by following the modular monolith blueprint described.

Frequently Asked Questions about dotnet-expert

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I structure a modular monolith in ASP.NET Core?

Implement the Result pattern in .NET to return success or structured errors from business logic instead of throwing exceptions. This approach provides explicit error handling and prevents unhandled exception overhead in your MediatR CQRS pipelines.

How do I add FluentValidation to a MediatR CQRS pipeline?

Add FluentValidation to a MediatR CQRS pipeline by configuring a validation behavior in the pipeline. This automatically validates commands and queries before they reach their handlers, ensuring input integrity and decoupling validation from business logic.

Can I use EF Core 9 with strongly-typed IDs in a clean architecture?

EF Core 9 supports strongly-typed IDs within a clean architecture to ensure data integrity across feature domains. Strongly-typed IDs prevent identifier mix-ups across domain boundaries while EF Core handles the underlying database value conversions.

What is the best way to secure ASP.NET Core APIs with JWT?

Securing ASP.NET Core APIs with JWT involves configuring JWT-based authentication middleware to validate tokens and authorize access. This method secures scalable data access across modular feature domains without coupling security logic to business handlers.

When should I use the Result pattern instead of throwing exceptions in C#?

Use the Result pattern instead of throwing exceptions in C# for expected business logic failures like validation errors or rule violations. Reserve exceptions for truly unexpected system failures to keep application flow normal and reduce performance overhead.