Answer
Controllers handle incoming HTTP requests.
- Decorated with
[ApiController]and[Route] - Contain action methods
- Use dependency injection via constructor
- Return IActionResult or data objects
Controllers handle incoming HTTP requests.
[ApiController] and [Route]This answer has been peer-reviewed by industry experts holding senior engineering roles to ensure technical accuracy and relevance for modern interview standards.
Sign in to access all features and personalize your learning experience.
Source: SugharaIQ