Learn Minimal APIs from start to finish. Perfect for beginners.

Minimal APIs tutorials

How to migrate from controllers to Minimal APIs
How to migrate from controllers to Minimal APIs

Learn why Minimal APIs are now recommended in .NET and follow a step-by-step guide to migrate from controllers to Minimal APIs with versioning and Swagger.

The simplest way to secure a Minimal API (With Swagger)
The simplest way to secure a Minimal API (With Swagger)

Secure your .NET Minimal API quickly using API key authentication, with full Swagger support for testing and protecting endpoints.

Minimal APIs: Fix missing OpenAPI response documentation
Minimal APIs: Fix missing OpenAPI response documentation

Learn why Minimal APIs often miss OpenAPI response types and how to fix missing 404, 400, and 500 responses using TypedResults and Produces methods.

ASP.NET Core route constraints: A quick guide for developers
ASP.NET Core route constraints: A quick guide for developers

Learn ASP.NET Core route constraints in this quick guide for developers. Fix routing issues fast and improve API accuracy with simple, clear examples.

How to upload files in an ASP.NET Core Web API
How to upload files in an ASP.NET Core Web API

Learn how to upload files with IFormFile and IFormFileCollection using minimal APIs in ASP.NET Core, and how to generate antiforgery tokens.

How to add unit testing to Minimal APIs routes using xUnit
How to add unit testing to Minimal APIs routes using xUnit

Learn how to unit test minimal API endpoint handlers in ASP.NET Core using xUnit by organising routes and handlers into separate classes.

Add API key authentication to an Minimal API endpoint
Add API key authentication to an Minimal API endpoint

Learn how to add API key authentication to minimal API endpoints using a saved key in the config and apply a fallback policy to secure all routes.

Minimal API filters: Run code before the endpoint handler
Minimal API filters: Run code before the endpoint handler

Learn how to add multiple endpoint filters to minimal API routes to run custom logic before and after your endpoint handlers.

TypedResults or Results for Minimal API responses?
TypedResults or Results for Minimal API responses?

Learn when to use TypedResults vs Results in minimal APIs and explore the different response types available for returning API responses.

How to use parameter binding for routes in Minimal APIs
How to use parameter binding for routes in Minimal APIs

Learn how to use parameter binding in minimal API routes with wildcards and constraints, and how to use them in endpoint handlers with special types.