Prefer Minimal APIs when the surface is small to medium and you want concise endpoint definitions.
Good defaults:
organize endpoints with route groups
keep route handlers thin
move business logic into services
prefer TypedResults over untyped results
use endpoint filters when cross-cutting behavior belongs at the endpoint layer
use built-in validation support on supported target frameworks
Minimal API reminders:
handler parameters can be bound from route, query, headers, body, form, or DI
authorization can be applied with RequireAuthorization
return IResult or TypedResults when response shape matters
use OpenAPI support for discoverable contracts
On .NET 10, Minimal APIs support built-in validation with AddValidation(). Use that instead of inventing parallel validation infrastructure when the target framework supports it.
Use dotnet new webapiaot only when native AOT is an explicit deployment requirement. Treat it as a constraint that affects library choice, reflection, JSON patterns, and compatibility.