
Web API Development
REST principles, HTTP verbs, status codes, content negotiation, versioning, API design
1Which REST principle requires that an API stores no session state between requests?
Which REST principle requires that an API stores no session state between requests?
Risposta
The statelessness principle requires that each request contains all necessary information to be processed. The server maintains no session context between calls. This improves scalability as requests can be handled by any server without state sharing.
2Which HTTP verb should be used to create a new resource in a REST API?
Which HTTP verb should be used to create a new resource in a REST API?
Risposta
POST is the standard HTTP verb for creating new resources. It is not idempotent: each call creates a new instance. The server typically determines the URI of the created resource and returns it via the Location header with a 201 Created status.
3Which HTTP status code should be returned after a successful resource creation with POST?
Which HTTP status code should be returned after a successful resource creation with POST?
Risposta
The 201 Created status code indicates that a new resource has been successfully created. It should be accompanied by a Location header containing the URI of the created resource. This allows the client to immediately retrieve the resource via GET, unlike 200 OK which doesn't provide this semantic.
What is the main difference between PUT and PATCH in a REST API?
Which HTTP status code should be returned when a requested resource does not exist?
+19 domande da colloquio
Altri argomenti di colloquio .NET
C# Basics
LINQ & Delegates
C# Language Essentials
ASP.NET Core Fundamentals
ASP.NET Core Request Lifecycle
Configuration & Settings
Application Lifecycle
Dependency Injection
Entity Framework Core
Minimal APIs
Async in ASP.NET Core
Authentication & Authorization
HttpClient & Networking
JSON Serialization
Entity Framework Core Advanced
C# Advanced Features
Clean Architecture
Logging, Monitoring & Observability
Unit Testing & xUnit
Integration Testing
Docker & Containerization
NuGet Package Management
Memory Management & GC
Reactive Programming
Async/await & Patterns
.NET Design Patterns
Performance Optimization
Security & Best Practices
SignalR & Real-time
Microservices Architecture
Padroneggia .NET per il tuo prossimo colloquio
Accedi a tutte le domande, flashcards, test tecnici, esercizi di code review e simulatori di colloquio.
Inizia gratis