4xx Client Error
You need to prove who you are before you can access this. Please log in or provide valid credentials.
Use 401 when authentication is missing, invalid, or expired and the client can authenticate.
GET https://api.example.test/api/users401 Unauthorized
# Headers
WWW-Authenticate: Bearer realm="api"
Content-Type: application/json
# Body
{
"error": "unauthorized"
}API requires authentication but no credentials provided
GET https://api.example.test/api/profile
# Headers
Authorization: Bearer <expired-jwt>401 Unauthorized
# Headers
WWW-Authenticate: Bearer realm="api"
Content-Type: application/json
# Body
{
"error": "unauthorized"
}Token was valid once but has now expired