Loading skill
Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Designs ASP.NET Core Minimal APIs with handler-first endpoints, route groups, filters, and guidance on choosing them over controllers.
95% 100%+5 ptsof test cases passed
Passed 22 of 22 test cases with the skill, and 21 of 22 without it.
3 of 3 safety checks passed
Problem: All endpoints defined directly in Program.cs becomes unmaintainable.
// BAD: Everything in Program.cs
var builder = WebApplication.CreateBuilder(args);
var app = builder.Build();
app.MapGet("/products", async (AppDb db) => await db.Products.ToListAsync());
app.MapGet("/products/{id}", async (int id, AppDb db) => await db.Products.FindAsync(id));
app.MapPost("/products", async (Product p, AppDb db) => { db.Add(p); await db.SaveChangesAsync(); return p; });
// ... 50 more endpoints
app.MapGet("/orders", async (AppDb db) => await db.Orders.ToListAsync());
// ... 50 more endpoints
app.MapGet("/customers", async (AppDb db) => await db.Customers.ToListAsync());
// ... and so on
app.Run();
Solution: Use extension methods to organize endpoints by domain.
// GOOD: Organized via extension methods
app.MapProductEndpoints();
app.MapOrderEndpoints();
app.MapCustomerEndpoints();
Problem: Repeating configuration across related endpoints.
// BAD: No route groups, repetitive configuration
Skills that do similar work, with their benchmark result.
Next to this one in the catalogue, plus more from the same author.