> **For coding agents and LLMs:** This is one Social Fetch marketing page (markdown export). For API orientation start with [`/llms.txt`](https://www.socialfetch.dev/llms.txt); for auth and crawl rules use [`/agents.txt`](https://www.socialfetch.dev/agents.txt); for every operation use [`/llms-endpoints.txt`](https://www.socialfetch.dev/llms-endpoints.txt).

## This page

- **On-site (HTML):** <https://www.socialfetch.dev/platforms/hackernews/users-username-comments>
- **Markdown (.mdx) URL:** <https://www.socialfetch.dev/platforms/hackernews/users-username-comments.mdx>

---

# Hacker News User Comments API

Page a user's comments newest first — text, parent ids, and item URLs for author voice analysis.

`GET /v1/hackernews/users/{username}/comments` lists comments for a case-sensitive username, newest first. Optional zero-based `page` and `pageSize` (1–50, default 20) control the window (up to 1,000 accessible hits). On `found`, `data.items` are comment-shaped rows with text, parentId, and itemUrl; `data.page` reports hasMore and nextPage. `not_found` returns null user and empty items.

Credit pricing for this operation comes from the API registry and appears on this page, and `meta.creditsCharged` is the billing source of truth. Pair with comment context when you need the root story for a specific comment id.

## Request

- **Endpoint:** `GET /v1/hackernews/users/{username}/comments`
- **Credits:** 1 credit
Failed requests are free
- **Input:** by username
- **Full reference:** [docs](https://www.socialfetch.dev/docs/api/v1/hackernews/users/username/comments/get)
- **Platform page:** [/platforms/hackernews](https://www.socialfetch.dev/platforms/hackernews)

## FAQ

### How do I list a Hacker News user's comments?

Call GET /v1/hackernews/users/{username}/comments with your Social Fetch API key in the x-api-key header. Pass the case-sensitive username. Optionally set page and pageSize. Read data.lookupStatus, then data.items.

### How many credits does listing user comments cost?

Pricing is documented on the operation in the API registry (shown on this page). Confirm on every response with meta.creditsCharged — that field is the billing source of truth.

### How does pagination work on user comments?

Use zero-based page and pageSize. When data.page.hasMore is true, request nextPage with the same username and pageSize. Do not invent cursors — this route uses page indexes.

### What fields are in each comment item?

Items are comment-typed and can include id, author, createdAt, text, parentId, childIds, dead, deleted, and itemUrl. Title and url are typically null on comments. Exact fields live in the OpenAPI schema.

### User comments vs story comments vs comment context?

User comments lists one author's comments across threads. Story comments pages one story's tree. Comment context expands a single comment id upward to the root story.

### What does lookupStatus mean?

found means the username resolved and items may be returned. not_found means the user does not exist. Always branch on lookupStatus before writing rows.

### Can I use this for voice or reputation analysis?

Yes. Teams page recent comments, store text keyed by id, and optionally call comment context for thread titles when a reply needs fuller context. Persist meta.requestId per page.
