Free tools

HTTP 401 Unauthorized

The request is missing valid authentication. Free reference, no signup.

401 Unauthorized

MeaningThe request is missing valid authentication.
WhenNo Authorization header, a bad token, or an expired session.
CausesA missing API key, a rotated key, or a logged-out user.
FixSend valid credentials. Trigv returns 401 when the API key is missing or unknown.
RetryRetry after refreshing the credential, not in a tight loop.
Alert?Usually no. Alert if a key that used to work starts getting 401, because it was revoked or rotated.

Runs in your browser. Nothing you enter is stored.

Most 401s are not an incident

Alert if a key that used to work starts getting 401, because it was revoked or rotated.

curl -sS -X POST https://api.trigv.com/v1/events \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer $TRIGV_API_KEY" \
  -d '{"channel":"ops","title":"HTTP 401","level":"warning"}'

How to use it

  1. Read what 401 means before changing a retry loop.
  2. Check the common causes against the response body and the server log.
  3. Follow the retry note. Retrying a 400 with the same body will fail again.
  4. Alert only in the cases the verdict describes.

About this tool

HTTP 401 Unauthorized means The request is missing valid authentication. Servers send it when No Authorization header, a bad token, or an expired session.

Common causes: A missing API key, a rotated key, or a logged-out user. The practical fix is: Send valid credentials. Trigv returns 401 when the API key is missing or unknown.

Retry: Retry after refreshing the credential, not in a tight loop.

Alert on it? Usually no. Alert if a key that used to work starts getting 401, because it was revoked or rotated.

Trigv is a push for the moment a status starts mattering, not a log of every response. If the code is one you should hear about, the snippet posts a single event with level error or warning. The status page itself does not call your API.

Questions

What is HTTP 401?

The request is missing valid authentication.

Should the client retry?

Retry after refreshing the credential, not in a tight loop.

Should I alert on it?

Usually no. Alert if a key that used to work starts getting 401, because it was revoked or rotated.

How is this different from reading the spec?

The page adds a plain retry note and an alert verdict for people running the service, not only for people parsing the response.