A messaging channel with a session behind it โ WhatsApp Web, a paired device, an OAuth-backed API โ can go dark while the process stays up. /health answers "is the process alive," not "can this thing actually deliver," and those are different questions that quietly diverge.
We hit this running our own WhatsApp automation in production: the paired device went unauthenticated (needed a fresh QR scan) while the service process kept running untouched. The only check most /health handlers implement โ is the process alive and answering HTTP โ stayed green the entire time. Outbound messages queued instead of failing loudly; the first real signal was silence, not an alert.
function naiveHealth(channel) {
return { ok: channel.alive };
}
That's a correct answer to the wrong question. The one that matters for anything session-based: is the session behind this endpoint currently authenticated, and has it proven that recently by actually sending something?
node check.js --demo
Zero dependencies, no network โ reproduces the class in ten lines: a channel that's alive, unauthenticated, and hasn't sent anything in 6 hours, checked two ways.
Against your own health endpoint (built-in http/https only, still zero deps):
node check.js --url http://localhost:PORT/health [--field authenticated]
It tells you one of three things: the JSON has no authenticated-state field at all (this failure class is invisible to you today), the field says false while the HTTP status says 200 (the false green, live), or the two agree.
ok already means.authenticated: true left over from before a session silently expired is exactly as misleading as not checking at all โ pair it with a "proved it worked recently" timestamp and fail once that goes stale.Skip the second part and you've only moved the false green one hop later โ from "checks liveness" to "checks a flag that never gets updated."
/health distinguish "process is up" from "the session behind this endpoint is currently usable"?