WWW-Authenticate
Response header, cookies & auth
Sent with 401 responses to name the authentication scheme the server expects.
WWW-Authenticate: Bearer realm="api", error="invalid_token"
Basic triggers the browser's built-in login dialog. APIs use Bearer for tokens and can add error details.
Check it on a live site
Run a header check on any URL to see whether and how it sends WWW-Authenticate.
Specification: RFC 9110 §11.6.1