dotnet-domain-modeling

Implement Domain-Driven Design tactical patterns in C# for domain models.

10|Updated Jan 28, 2026
One-click install
npx skills add https://github.com/AGIBuild/Agibuild.Fulora --skill dotnet-domain-modeling
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dotnet-domain-modeling
Source: https://github.com/AGIBuild/Agibuild.Fulora/tree/main/.cursor/skills/dotnet-domain-modeling
Command: npx skills add https://github.com/AGIBuild/Agibuild.Fulora --skill dotnet-domain-modeling

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides a comprehensive guide to implementing Domain-Driven Design (DDD) tactical patterns in C#, enabling developers to build robust, maintainable, and business-logic-rich domain models.

Core Features & Use Cases

  • Aggregate Roots & Entities: Defines base classes and patterns for creating entities with identity and aggregate roots that manage domain events.
  • Value Objects: Demonstrates the creation and usage of immutable value objects for representing concepts like money and addresses.
  • Domain Events: Explains how to define, raise, and dispatch domain events to decouple domain logic.
  • Domain Services: Illustrates how to encapsulate business logic that doesn't fit within a single entity.
  • Repository Contracts: Outlines the design principles for repository interfaces in the domain layer.
  • Use Case: When building a complex e-commerce backend, use these patterns to model orders, customers, and products, ensuring business rules are enforced correctly and consistently within the domain layer.

Quick Start

Implement a new Order aggregate root using the provided C# base classes and patterns.

Frequently Asked Questions about dotnet-domain-modeling

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

FAQPage Schema
How do I implement domain-driven design tactical patterns in C#?

You implement aggregate roots and value objects in C# by using base classes that encapsulate business logic and protect invariants. This creates rich domain models independent of persistence technology, ensuring rules are enforced consistently.

What is the best way to model aggregate roots and domain events in a .NET application?

The best way to model aggregate roots and domain events in .NET is to define base classes where aggregate roots manage and dispatch events. This decouples domain logic by allowing events to be raised and handled independently within the domain layer.

How do I create immutable value objects for a C# domain model?

You create immutable value objects in a C# domain model by leveraging specific design patterns that represent concepts like money or addresses. These value objects ensure domain integrity by preventing state mutation after instantiation.

When do I need domain services versus aggregate roots in DDD?

You need domain services in DDD when business logic spans multiple entities and does not fit naturally within a single aggregate root. Domain services encapsulate this cross-entity behavior, keeping aggregate roots focused on their own invariants.

Can I design repository contracts independent of persistence technology in C#?

Yes, you can design repository contracts independent of persistence technology in C# by defining repository interfaces strictly within the domain layer. This ensures the domain model remains decoupled from database implementation details.

Does DDD tactical modeling work for complex e-commerce backend development?

DDD tactical modeling works effectively for complex e-commerce backend development by providing patterns to model orders, customers, and products. It ensures business rules are enforced correctly and consistently within the domain layer.