Entity Design (EF Core)

Design EF Core entities with Fluent API mappings and owned types.

53|27|Updated Jan 23, 2026
One-click install
npx skills add https://github.com/andresharpe/dotbot-v3 --skill entity-design-ef-core
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Entity Design (EF Core)
Source: https://github.com/andresharpe/dotbot-v3/tree/main/profiles/dotnet-ef/prompts/skills/entity-design
Command: npx skills add https://github.com/andresharpe/dotbot-v3 --skill entity-design-ef-core

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill streamlines the process of designing database entities for Entity Framework Core, ensuring proper relationships, value objects, and configurations are established from the outset.

Core Features & Use Cases

  • Entity Modeling: Define new entities and their properties within an EF Core DbContext.
  • Relationship Mapping: Configure one-to-one, one-to-many, and many-to-many relationships using Fluent API.
  • Value Objects & Owned Types: Implement complex types like addresses or monetary values as owned types.
  • Configuration: Apply advanced configurations such as table-per-hierarchy, concurrency tokens, and shadow properties.
  • Use Case: When creating a new Order entity, you can use this Skill to define its relationship with an OrderItem entity and configure ShippingAddress as an owned type.

Quick Start

Use the Entity Design skill to create a new 'Product' entity with a 'Category' navigation property.

Frequently Asked Questions about Entity Design (EF Core)

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

FAQPage Schema
How do I configure EF Core entity relationships using Fluent API?

EF Core entity relationships are configured using Fluent API to define one-to-one, one-to-many, and many-to-many mappings within a DbContext. This establishes structured database schema designs and properly configured navigation properties for .NET applications.

What is the best way to implement value objects in Entity Framework Core?

The best way to implement value objects in Entity Framework Core is by configuring them as owned types. You can map complex types like addresses or monetary values directly to your entities, ensuring proper domain modeling and schema structure.

How do I set up advanced EF Core configurations like table-per-hierarchy and concurrency tokens?

Advanced EF Core configurations like table-per-hierarchy, concurrency tokens, and shadow properties are set up by applying specific Fluent API mappings during entity design. This ensures your database schema adheres to .NET application best practices.

Does this approach support defining navigation properties for a new entity in EF Core?

Yes, this approach fully supports defining navigation properties for new entities in EF Core. You can create an entity like Product and define its relationship with a Category entity using structured Fluent API mappings from the start.

When should I use Fluent API over other methods for database modeling in C#?

You should use Fluent API for database modeling in C# when you need structured schema design and advanced configurations like relationship mapping, value objects, and owned types. It provides a robust way to enforce best practices for entity definition in EF Core.