350-201(NEW-127Q) · Question #95
350-201(NEW-127Q) Question #95: Real Exam Question with Answer & Explanation
The correct answer is B. 401. 401 Unauthorized is returned when a request lacks valid authentication credentials - the server is essentially saying "I need more information about who you are before I can proceed." It's the standard response for endpoints that require a login or token the client hasn't provide
Question
Options
- A500
- B401
- C403
- D404
Explanation
401 Unauthorized is returned when a request lacks valid authentication credentials - the server is essentially saying "I need more information about who you are before I can proceed." It's the standard response for endpoints that require a login or token the client hasn't provided (or provided incorrectly).
Why the others are wrong:
- A (500) is an Internal Server Error - a problem on the server side, unrelated to who the user is.
- C (403) means Forbidden: the server knows who you are (authenticated) but you don't have permission to access the resource - no extra info will help.
- D (404) means Not Found - the resource simply doesn't exist at that URL; user identity is irrelevant.
Memory tip: Think of 401 as "Who are you?" and 403 as "I know who you are - you're just not allowed in." Authentication (401) comes before authorization (403), just like logging in comes before checking permissions.
Topics
Community Discussion
No community discussion yet for this question.