← All APIs Network

Hacker News Data API

Get current Hacker News lists or scan a past date for stories, jobs, and polls, with optional comment threads.

This tool reads live information from Hacker News, a popular website where people share and discuss technology news. You can either ask for a current list of stories (like the Top, New, Best, Ask, Show, or Job lists) or ask for every story, job posting, and poll that was posted on one specific calendar day in the past. You can also choose to pull in the discussion comments underneath each story, including nested replies several levels deep.

POSThttps://hackernews-data.underscoredone.com/fetch
Pricing

$0.01 per request — pay via x402/USDC. No account needed.

How to call

Call this when you need Hacker News content: either a current ranked list (top, new, best, ask, show, job) or every story/job/poll posted on a given UTC date. Set 'date' to switch to date mode; leave it empty to use category mode. Use 'reply_depth' and 'comment_limit' sparingly since higher values take longer. For date mode, if 'range_complete' is false in the response, call again passing the returned 'next_page_token' as 'page_token' to continue scanning the same day.

Input parameters
NameTypeRequiredDescription
categorystring/nullnoWhich current list to pull from: top, new, best, ask, show, or job. Ignored if a date is given.
datestring/nullnoA calendar day in YYYY-MM-DD format (UTC). If given, the tool switches to scanning that whole day instead of using a category.
limitinteger/nullnoThe largest number of results to return. Default is 30, maximum is 200.
comment_limitinteger/nullnoHow many top-level comments to fetch per story. Default 10, maximum 100, 0 means none.
reply_depthinteger/nullnoHow many levels of nested replies to fetch below each comment. Default 0, maximum 5.
replies_per_commentinteger/nullnoThe largest number of replies fetched per comment at each level. Default 5, maximum 20.
page_tokeninteger/nullnoA resume point from a previous date-scan response, used to continue scanning the same day where it left off.
Example requests
Typical input
{
  "category": "top",
  "limit": 5,
  "comment_limit": 3,
  "reply_depth": 1
}
Zero or empty input
{
  "category": "top",
  "limit": 0,
  "comment_limit": 0,
  "reply_depth": 0
}
Invalid input (400 error)
{
  "category": "banana",
  "date": "2026-13-40",
  "limit": -5
}
Large input
{
  "date": "2026-06-29",
  "limit": 200,
  "reply_depth": 5,
  "replies_per_comment": 20
}
Example response
{
  "api_version": "1.0.0",
  "mode": "get_stories",
  "category": "top",
  "date": null,
  "count": 5,
  "scanned": null,
  "range_complete": null,
  "next_page_token": null,
  "results": [
    {
      "id": 48753715,
      "item_type": "story",
      "category": "top",
      "title": "ZCode \u2013 Harness for GLM-5.2",
      "author": "chvid",
      "url": "https://zcode.z.ai/en",
      "points": 234,
      "posted_at": 1782943416,
      "comment_count": 223,
      "comments": [
        {
          "id": 48752128,
          "author": "seizethecheese",
          "posted_at": 1782935074,
          "body": "I'm somewhat surprised that this is not open source...",
          "reply_count": 9,
          "replies": []
        }
      ]
    }
  ]
}
Error responses
StatusMeaning
400Bad request — your input failed validation or could not be processed. Check the detail field for specifics.
402Payment required. Send a signed USDC payment on Base Mainnet using the x402 protocol.
422Unprocessable — a required field is missing or the wrong type. Check the detail field for specifics.
Links