Agent skill · Backend & API

dotnet-minimal-api-endpoints

Generates Minimal API endpoints following Microsoft's recommended approach. Creates fast, testable HTTP APIs with minimal code using MapGet/MapPost/MapPut/MapDelete. Preferred over controller-based APIs for new projects.

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill 07-2-dotnet-minimal-api-endpoints --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 19 KB
Bundled scripts: none
Version: 1.0.0
Requires: MediatR, FluentValidation
Path: skills/api/07-2-dotnet-minimal-api-endpoints/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

Review
written from the skill's own SKILL.md · Aug 5, 2026

What it does

Generates Minimal API endpoints following Microsoft's recommended approach for new projects. Creates HTTP APIs with minimal boilerplate using MapGet/MapPost/MapPut/MapDelete, and structures them under a feature-based Endpoint folder layout. It emphasizes testability and uses typed results for responses.

How it works

  • Provides a ready-to-use template for Complete CRUD endpoints including MapGroup-based wiring, standard HTTP mappings (Get by id, Get all, Create, Update, Delete).
  • Includes handler methods GetById, GetAll, Create, Update, Delete that interact with MediatR via an ISender to dispatch queries/commands and return TypedResults (e.g., Ok, Created, NoContent, NotFound, BadRequest).
  • Demonstrates endpoint registration in Program.cs via Map{Feature}Endpoints(), and shows how to structure Request DTOs (RequestCreate{Entity}}, RequestUpdate{Entity}) and their usage in CRUD handlers.
  • Shows examples of authorization patterns, API versioning via MapGroup, and validation via a ValidationFilter<T> endpoint filter.
  • Includes templates for standard CRUD, complex endpoints with MapGroup, and usage notes for API documentation (OpenAPI/Swagger).

When to use it

  • When starting a new .NET 8+ project that aims to use Minimal APIs instead of controllers.
  • When following Microsoft's recommended Minimal API patterns and wanting a structured, testable endpoint setup with MediatR integration.

What it can touch

  • Endpoints are wired as extension methods on IEndpointRouteBuilder via Map{Feature}Endpoints.
  • It references MediatR (ISender) and FluentValidation in validation flows.
  • It includes usage of TypedResults for typed, testable responses and OpenAPI metadata generation.

Caveats

  • Dependencies required: MediatR, FluentValidation.
  • Exposes examples with authorization and permissions; real projects must supply Permissions.{Entities}Write and related policies.
  • License: MIT
From the SKILL.md

# Minimal API Endpoints Generator ## Overview **Microsoft's recommended approach for new projects.** Minimal APIs provide a simplified, high-performance way to build HTTP APIs with less boilerplate than controllers. ### Benefits Over Controllers - ✅ **Simpler syntax** - Less code, more productivity - ✅ **Better performance** - Reduced overhead - ✅ **Easier testing** - Testable handler methods - ✅ **Modern approach** - Latest .NET features - ✅ **Less ceremony** - No controller classes needed ## Quick Reference | HTTP Method | Extension Method | Use Case | |-------------|------------------|----------| | `MapGet` | Read single/list | `app.MapGet("/users/{id}", ...)` | | `MapPost` | Create | `app.MapPost("/users", ...)` | | `MapPut` | Update (full) | `app.MapPut("/users/{id}", ...)` | | `MapDelete` | Delete | `app.MapDelete("/users/{id}", ...)` | --- ## Endpoint Structure ``` /API/Endpoints/ ├── {Feature}/ │ ├── {Feature}Endpoints.cs │ └── Request{Action}{Entity}.cs └── ... ``` --- ## Template: Complete CRUD Endpoints ```csharp // src/{name}.api/Endpoints/{Feature}/{Feature}Endpoints.cs using {name}.application.{feature}.Create{Entity}; using {name}.application.{feature}.Delete{Entity}

What's inside
Steps it walks through
  1. Overview
  2. Benefits Over Controllers
  3. Quick Reference
  4. Endpoint Structure
  5. Template: Complete CRUD Endpoints
  6. Template: Request DTOs
  7. Template: Program.cs Registration
  8. Template: Complex Endpoints with MapGroup
  9. Template: Endpoint Filters (Validation)
  10. Template: Authorization
  11. Template: API Versioning with MapGroup
  12. TypedResults Pattern
  13. Benefits of TypedResults
  14. Testing Minimal API Endpoints
Ships with 1 file
  • metadata.json
More from claude-skill-registry
All skills →
About this skill
What does the dotnet-minimal-api-endpoints skill do?

Generates Minimal API endpoints following Microsoft's recommended approach. Creates fast, testable HTTP APIs with minimal code using MapGet/MapPost/MapPut/MapDelete. Preferred over controller-based APIs for new projects.

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill 07-2-dotnet-minimal-api-endpoints --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going