ASP.NET Core Minimal APIs in C#
Build Production-Ready RESTful APIs with Modern .NET
Learn the streamlined approach that reduces boilerplate code while maintaining enterprise-grade quality, security, and performance. Move beyond basic CRUD operations. This hands-on course covers authentication, authorization, testing, error handling, logging, performance optimization, and architectural patterns—everything needed to build production-ready APIs that scale.
Audience
Backend developers wanting to master modern API development with .NET, C# developers ready to adopt Minimal APIs for new projects, ASP.NET developers upgrading from traditional controllers or older .NET versions, Full-stack developers needing a solid foundation in API design and implementation. Software architects evaluating Minimal APIs for microservices or enterprise systems
Basic C# knowledge (6+ months experience). Understanding of HTTP and REST concepts helpful but not required.
Why Minimal APIs?
- Fewer files and classes to manage
- Direct route-to-handler mapping
- Reduced ceremony for simple endpoints
- Faster startup times
- Reduced memory footprint
- Optimized for high-throughput scenarios
- Leverages latest C# language features
- Functional programming patterns
- Strong typing with type inference
- Microservices architecture
- Serverless functions
- Lightweight APIs
- High-performance scenarios
- Modern cloud-native applications
Content
- Minimal APIs vs MVC controllers comparison
- Performance characteristics and benchmarks
- When to use Minimal APIs
- .NET SDK installation and verification
- IDE setup (Visual Studio, VS Code, Rider)
- Project structure and organization
- ASP.NET Core architecture
- Program.cs and WebApplication
- Middleware pipeline
- Configuration system (appsettings.json, environment variables, user secrets)
- Endpoint definitions and lambda expressions
- Route templates, parameters, and constraints
- HTTP verbs (GET, POST, PUT, DELETE, PATCH)
- Request binding (route, query, body, headers, forms)
- Response serialization and content negotiation
- IResult interface fundamentals
- Results vs TypedResults comparison
- Common result types (Ok, Created, NotFound, BadRequest, NoContent)
- Custom result types and content negotiation
- Proper HTTP status codes and headers
- OpenAPI documentation benefits
- OpenAPI/Swagger setup and configuration
- Testing endpoints with Swagger UI
- Customizing API documentation with XML comments
- API versioning strategies
- Generating client code from OpenAPI specs
- Middleware pipeline
- Custom middleware patterns (inline, class-based, factory-based)
- Endpoint filters for request/response manipulation
- Filter ordering and execution flow
- When to use middleware vs filters
- DataAnnotations for simple validation
- FluentValidation for complex scenarios
- Custom validators for business rules
- Endpoint filters for validation
- DI fundamentals in ASP.NET Core
- Service lifetimes (transient, scoped, singleton)
- Constructor injection in endpoints
- Options pattern for configuration
- EF Core setup and DbContext configuration
- Entity modeling and relationships (one-to-many, many-to-many)
- Migrations workflow
- LINQ queries (filtering, sorting, projection, aggregation)
- IQueryable vs IEnumerable
- Layered architecture
- Domain, Application, Infrastructure, and API layers
- Dependency inversion
- Project structure
- Repository pattern
- Generic repository implementation
- Unit of Work pattern
- EF Core integration
- Unit testing
- Mocking
- Testing Minimal API endpoints
- Integration testing with WebApplicationFactory
- Testing authenticated endpoints
- AAA (Arrange-Act-Assert) pattern
- ASP.NET Core Identity setup
- JWT token generation and validation
- User registration and login endpoints
- Refresh token patterns
- Role-based authorization
- Policy-based authorization
- Claims and custom policies
- [Authorize] attribute
- Global exception middleware
- Problem Details (RFC 7807)
- Custom exception types
- Development vs production error details
- Structured logging with Serilog
- Log levels
- Multiple sinks (console, file, database)
- Correlation IDs
- Extension methods for endpoint registration
- Route groups and prefixes
- Vertical slice architecture
- Feature-based organization
- Response caching strategies
- In-memory caching with IMemoryCache
- Distributed caching concepts
- Rate limiting and throttling
- EF Core query optimization (AsNoTracking, compiled queries)
- Async/await patterns
- Health checks
- CORS configuration
- Environment-specific configuration
- Background services and hosted services
- Azure deployment
- Monitoring
Instructor
Do you have any course related questions, please contact
- Mette Rosenløv Vad
- Konsulent
- +45 72202432