PUT now behaves correctly. If you omit a required field, the API rejects the request. PATCH is the only partial update method.
course.course and notice the validation error.Run a request to see output...
This app now enforces classic PUT semantics. If a student needs name, email, and course, a PUT request must send all three.
PATCH only changes the provided fields and leaves the rest untouched. It also rejects unknown fields to keep the lesson clear.
Use OPTIONS to inspect allowed methods and HEAD to test the route without returning a full payload body.