# Hacker News Comments & Threads

> Hacker News Comments & Threads is a paid API for AI agents from social.duoleads.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-29).

Fetches a single Hacker News story or comment by ID or URL along with its direct replies, skipping deleted and dead entries, with cursor-based pagination.

## Facts

- Endpoint: GET https://social.duoleads.com/v1/hackernews/thread?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-29
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/hacker-news-comments-threads-9ddff154
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_en2uOTtnmvtuIA1Xg68A7

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability hacker-news-comments-threads-9ddff154
```

Example prompt: Pull up the Hacker News thread for item ID 40000001 and show me the first 10 direct replies — skip any deleted or dead ones.

## When to prefer this

Choose this endpoint when you need the full discussion thread for a specific Hacker News item — known by ID or URL — including paginated direct replies with metadata like score and reply count. It is ideal for retrieving structured comment data on a particular submission rather than searching across HN. Prefer Hacker News Search & Stories for keyword discovery and this endpoint for deep-diving into a known thread.

## Known failure modes

- Invalid or malformed item ID returns a bad-input response (not charged)
- Item ID not found on Hacker News returns a not-found response (not charged)
- No matching replies returns an empty items array with complete:true
- Cursor value out of range may return an empty page
- Network timeout or upstream Firebase/Algolia outage may cause transient errors

## How this service works

Hacker News Comments & Threads: one Hacker News story or comment by id or news.ycombinator.com URL with its direct replies (up to 8 per call, next_cursor for more), deleted and dead replies skipped. Per item the text as plain text, author, score, reply count, parent and time in the shared social schema. Bad input is free; not found or no match is not charged.

## Output

Returns a JSON object containing the requested story or comment item plus up to 8 direct replies (non-deleted, non-dead), each with ID, URL, plain-text content, type (post or comment), author handle, likes/replies metrics, parent ID, platform, and creation timestamp. Also includes a next_cursor for fetching additional replies, a complete flag, request ID, and source/disclaimer fields.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "id"
     ],
     "properties": {
      "id": {
       "type": "string",
       "maxLength": 200,
       "description": "The story or comment: a Hacker News item id (a positive whole number) or a news.ycombinator.com/item?id= URL."
      },
      "limit": {
       "type": "string",
       "pattern": "^[0-9]{1,4}$",
       "description": "Direct replies wanted, 1-50 (default 10); one call returns at most 8, next_cursor pages through the rest."
      },
      "cursor": {
       "type": "string",
       "maxLength": 6,
       "description": "next_cursor of the previous page (a reply offset)."
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "as_of": "2026-10-15T12:00:00.000Z",
  "items": [
   {
    "id": "40000001",
    "url": "https://news.ycombinator.com/item?id=40000001",
    "lang": null,
    "text": null,
    "type": "post",
    "title": "Show HN: Synthwidget, a synthetic widget",
    "author": {
     "handle": "synth_hn_user1",
     "verified": null,
     "followers": null,
     "display_name": null
    },
    "metrics": {
     "likes": 128,
     "views": null,
     "replies": 47,
     "reposts": null
    },
    "link_url": "https://example.invalid/synthwidget",
    "platform": "hackernews",
    "parent_id": null,
    "created_at": "2026-10-13T14:00:00.000Z",
    "media_urls": []
   },
   {
    "id": "40000011",
    "url": "https://news.ycombinator.com/item?id=40000011",
    "lang": null,
    "text": "Looks useful. How does it compare to the old one?",
    "type": "comment",
    "author": {
     "handle": "synth_hn_user4",
     "verified": null,
     "followers": null,
     "display_name": null
    },
    "metrics": {
     "likes": null,
     "views": null,
     "replies": 1,
     "reposts": null
    },
    "platform": "hackernews",
    "parent_id": "40000001",
    "created_at": "2026-10-13T14:10:00.000Z",
    "media_urls": []
   }
  ],
  "query": {
   "id": "40000001",
   "limit": 10,
   "cursor": null
  },
  "source": "public data via the Hacker News API (Algolia search and Firebase); not affiliated with Y Combinator",
  "complete": true,
  "platform": "hackernews",
  "disclaimer": "Public data via third-party providers; not affiliated with or endorsed by any platform. Do not use to profile, target or train AI on individuals.",
  "request_id": "01KEXAMPLE0000000000000000",
  "next_cursor": null
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/hacker-news-comments-threads-9ddff154/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from social.duoleads.com](https://www.zero.xyz/host/social.duoleads.com/llms.txt)
