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

.NET code examples

Interfaces in C#
Interfaces in C#

Download a C# interface code example that covers implementation, adding multiple interfaces to a class, default methods and access modifiers.

LINQ and lambda expressions in C#
LINQ and lambda expressions in C#

Download this LINQ and lambda expressions code example in C# including Where, Select, OrderBy, GroupBy, ToDictionary and many more methods.

Create your own custom middleware in ASP.NET Core
Create your own custom middleware in ASP.NET Core

Download an ASP.NET Core middleware example that covers how to create your own custom middleware and shows how to inject services.

Using EF Core navigation properties with Include()
Using EF Core navigation properties with Include()

A EF Core example showing how to use Include() to join navigation properties together, when not to use Include() and when you need to configure the join.

Polly resilience example in ASP.NET Core Web API
Polly resilience example in ASP.NET Core Web API

Download a Polly resilience example for ASP.NET Core Web API, covering retries, jitter, circuit breakers, timeouts, and logging.

.NET 10 Web API using Minimal APIs, EF Core and SQL Server
.NET 10 Web API using Minimal APIs, EF Core and SQL Server

Download a .NET 10 Web API integrated with Minimal APIs and SQL Server alongside Entity Framework Core and FluentValidation.

Learn C# basics
Learn C# basics

Download a C# code example to help you learn variables, types, conditionals, arrays, lists, loops, classes, structs, interfaces, enums and static classes.

Keyset vs offset pagination in EF Core
Keyset vs offset pagination in EF Core

See how keyset and offset pagination are implemented in EF Core, how indexes affect performance, so you decide which approach suits your application.

EF Core temporal tables in an ASP.NET Core Web API
EF Core temporal tables in an ASP.NET Core Web API

Download an EF Core temporal table code example in an ASP.NET Core Web API with configuration and historic data queries

Using exception handlers in an ASP.NET Core Web API
Using exception handlers in an ASP.NET Core Web API

See how to add exception handling to your ASP.NET Core Web API using IExceptionHandler, including validation errors and custom status codes.