Visão Geral
O curso ASP.NET Core Web API foi desenvolvido para profissionais que desejam criar APIs modernas, escaláveis e de alta performance utilizando o framework ASP.NET Core.
Durante o treinamento, você aprenderá na prática como desenvolver endpoints RESTful, aplicar boas práticas, segurança, versionamento, documentação com Swagger, autenticação com JWT, integração com bancos de dados via Entity Framework Core e publicação em ambiente produtivo.
A metodologia inclui aulas ao vivo via Microsoft Teams, com instrutor experiente no mercado, laboratório individual, exercícios práticos e apostilas exclusivas.
Conteúdo Programatico
Module 1 – Introduction to Web APIs
- What is an API?
- REST vs SOAP
- HTTP verbs, status codes and headers
- Introduction to ASP.NET Core Web API
- Project structure and configuration
Module 2 – Controllers and Routing
- Creating API controllers
- Attribute routing vs conventional routing
- Action results and HTTP response types
- Using built-in filters
- Customizing global API behavior
Module 3 – Models, DTOs and Validation
- Creating models and binding data
- Data annotations and custom validation
- Using DTOs and AutoMapper
- Error handling and validation patterns
Module 4 – Entity Framework Core for APIs
- Installing EF Core
- Creating DbContext and DbSets
- Code-first migrations
- CRUD operations
- Database relationships
- LINQ queries for APIs
Module 5 – Dependency Injection & Services Layer
- Understanding DI in ASP.NET Core
- Creating interfaces and service layers
- Repository pattern (optional)
- Business logic separation
Module 6 – Authentication & Authorization with JWT
- Introduction to authentication methods
- JWT (JSON Web Tokens) in depth
- Implementing login and token generation
- Protecting endpoints
- Role-based and policy-based authorization
Module 7 – API Documentation with Swagger
- Adding Swagger/OpenAPI
- Organizing endpoints in groups
- Customizing documentation
- Adding authentication to Swagger UI
- Best practices for API documentation
Module 8 – Consuming External APIs
- Using HttpClient
- Typed HttpClient
- Handling retries and resilience
- Integration patterns
Module 9 – API Versioning
- Why API versioning is important
- URL-based versioning
- Header-based versioning
- Query-string versioning
- Best practices
Module 10 – Logging, Monitoring & Error Handling
- Using built-in logging providers
- Serilog overview (optional)
- Custom error responses
- Exception filters
- Monitoring APIs in production
Module 11 – CORS (Cross-Origin Resource Sharing)
- What is CORS
- Allowing specific origins
- Configuring policies
- Security considerations
Module 12 – Testing Web APIs
- Unit testing controllers and services
- Integration testing
- Using Postman and Swagger for testing
- Mocking dependencies
Module 13 – Deployment
- Environment configuration
- Publishing to IIS
- Publishing to Docker containers
- Deployment to Azure App Service
Module 14 – Final Project
- Building a complete RESTful API
- Applying best practices and clean architecture concepts
- API documentation delivery
- Execution and final validation