cqrs-basics

Community

Implement clean CQRS with MediatR

AuthorFaysilAlshareef
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill provides clear guidance and patterns to avoid mixed responsibilities and tightly coupled logic by separating commands (writes) from queries (reads) when building .NET applications.

Core Features & Use Cases

  • Command and Query Patterns: Naming conventions and example request/response DTOs for Create/Update/Delete commands and Get/List queries.
  • Handlers and Pipeline Behaviors: Sample MediatR handlers, registration guidance, and pipeline behavior ordering for validation, logging, and transactions.
  • Integration Advice: Minimal API and Controller wiring examples, database query best-practices such as AsNoTracking, and folder organization for Clean Architecture and VSA projects.
  • Use Case: Build an order management feature with CreateOrderCommand handlers, validators, and ListOrdersQuery handlers that return paged responses.

Quick Start

Add CQRS by creating command and query types, register MediatR and pipeline behaviors, and move controller logic into handlers to enforce separation of concerns.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: cqrs-basics
Download link: https://github.com/FaysilAlshareef/dotnet-ai-kit/archive/main.zip#cqrs-basics

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.