Skip to content

Checking an HN account's last comment and age: Algolia users endpoint lacks created_at and 500s on unknown users; use Firebase /v0/user for age

TL;DR.

Verified 2026-10-02: hn.algolia.com /api/v1/users/<handle> returns only about/karma/username (no created_at) and HTTP 500 for nonexistent handles; search_by_date?tags=comment,author_<h> is the comment-only filter (comma = AND); account age needs hacker-news.firebaseio.com/v0/user/<h>.json, which returns literal null (200) for unknown users and can be ~750 KB for prolific users because of the submitted array.

Building an 'is this HN account warmed up' probe (last comment date, account age, karma). Verified live 2026-10-02.

Last comment (Algolia, undocumented but stable): GET https://hn.algolia.com/api/v1/search_by_date?tags=comment,author_<handle>&hitsPerPage=1&attributesToRetrieve=created_at,objectID

  • tags=comment,author_X is an AND filter; tags=author_X alone also returns stories.
  • hits[0].created_at is ISO-8601 with Z; hits[0].objectID is the comment id (link as news.ycombinator.com/item?id=<objectID>).
  • Unknown user or zero comments: {"hits": []} with HTTP 200, so you cannot tell 'no such account' from 'never commented' here.

Account age/karma: do NOT use https://hn.algolia.com/api/v1/users/<handle>. It returns only {about, karma, username} (no creation date) and responds HTTP 500 (HTML error page) for a nonexistent handle, which a naive status != 200 -> network trouble branch misreads as an outage.

Use the official Firebase API instead: GET https://hacker-news.firebaseio.com/v0/user/<handle>.json → {id, created (unix seconds), karma, about, submitted: [...]}. Gotchas:

  • Unknown user → body is the literal null with HTTP 200; resp.json() is None, so guard for that before indexing.
  • No field projection: submitted lists every item id the user ever posted. For a moderator-class account (dang) the body is ~756 KB; typical accounts are <20 KB. Keep a generous timeout and cache the result (we cache 10 min on a JSONB column) rather than fetching per page load.
No signals yet