create-datadriven-aspnetcore

Generates ASP.NET Core CRUD pages, controllers, and Minimal API endpoints backed by EF Core.

5.3k|403|Updated Feb 3, 2026
One-click install
npx skills add https://github.com/dotnet/skills --skill create-datadriven-aspnetcore
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: create-datadriven-aspnetcore
Source: https://github.com/dotnet/skills/tree/main/plugins/dotnet-data/skills/create-datadriven-aspnetcore
Command: npx skills add https://github.com/dotnet/skills --skill create-datadriven-aspnetcore

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Manually writing CRUD pages, controllers, and API endpoints for ASP.NET Core applications is repetitive and error-prone, especially when the generated code must match an existing project's CSS framework, layout conventions, and Entity Framework Core data model.

Core Features & Use Cases

  • Multi-pattern scaffolding: Generates Razor Pages, Blazor components, MVC controllers with views, and Minimal API endpoints without invoking CLI scaffolding tools.
  • EF Core integration: Creates or reuses DbContext classes, registers providers, and runs migrations for full database-backed CRUD workflows.
  • Convention matching: Inspects existing layouts, CSS frameworks (Bootstrap, Tailwind), and coding patterns so generated UI blends into the project.
  • Use Case: Ask the agent to scaffold Razor Pages with CRUD for a Product model backed by SQLite, and it generates the pages, DbContext, migration, and verifies the build end to end.

Quick Start

Ask the agent to scaffold CRUD Razor Pages for a model class in your ASP.NET Core project, specifying the .csproj path, DbContext name, and database provider.

Frequently Asked Questions about create-datadriven-aspnetcore

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

FAQPage Schema
How do I scaffold CRUD pages in ASP.NET Core without CLI tools?

Describe the model class, project path, DbContext name, and database provider in a natural-language request. The agent generates Razor Pages, Blazor components, MVC controllers, or Minimal API endpoints manually, matching your project's existing conventions.

How to generate Minimal API endpoints with Entity Framework Core?

Provide the model class, namespace, endpoints class name, and database provider. The agent creates a route group with GET, POST, PUT, and DELETE endpoints, adds OpenAPI metadata, and produces a .http file with requests ordered by dependency.

Does generated Blazor code work with EditForm and interactive render modes?

Yes. Generated Blazor components use = new() for [SupplyParameterFromForm] properties to prevent EditForm crashes, and Program.cs is configured with AddInteractiveServerComponents and AddInteractiveServerRenderMode only when the components actually use interactive rendering.

Can it scaffold CRUD for entities with foreign key relationships?

Yes. When the model has required foreign keys, the agent also scaffolds CRUD for parent entities so they can be created first, and orders .http requests so parent records are created before child records.

Why does the generated UI not match my project's styling?

The agent inspects your layout file, main CSS file, and existing pages before generating markup, so output follows your Bootstrap, Tailwind, or custom conventions. Mismatches typically occur when those files were not inspected first.

When should I not use this scaffolding approach?

Avoid it for non-ASP.NET Core projects such as class libraries or console apps, and when your team prefers CLI-based scaffolding tools. It is designed specifically for data-driven web artifacts backed by EF Core.