Search Hacker News
Search Hacker News by relevance or by date. Use tags to select stories, comments, polls, Show HN, Ask HN, front-page items or an author; query is optional when tags or numericFilters select the results, so a tags-only request returns the current front page or one author’s items. Filter timestamps and counts with numericFilters, restrict matching to chosen attributes, disable typo tolerance for exact matching, and select a results page.
/v1/hackernews/searchx-api-keyHeaders
Get your API keyYour ScrapeAtlas customer key. Create one on /account/ and set SCRAPEATLAS_API_KEY.
Free-text search term, 1–500 characters. Optional when tags or numericFilters is supplied. Quoted phrases and -exclusions are supported by the source index.
min 1 chars · max 500 chars
claude codeComma-separated source tags: story, comment, poll, pollopt, job, show_hn, ask_hn, launch_hn, front_page, author_<username> or story_<id>. Top-level commas are AND; a parenthesised group such as (story,comment) is OR. Defaults to story. At most 10 tags.
max 400 chars
storyComma-separated conditions on created_at_i, points or num_comments using <, <=, =, >= or > with an integer, for example created_at_i>1700000000,points>=100. At most 10 conditions. No filter by default.
max 400 chars
created_at_i>1756684800relevance (default) ranks by the source relevance score; date returns the newest matching items first.
one of: relevance, date
datefalse matches the query exactly; the source tolerates typos by default. Defaults to the source setting.
one of: true, false
Comma-separated attributes to match against: title, url, author, story_text or comment_text. At most 5. Defaults to all of them.
max 100 chars
true adds the source children ID list to each hit, bounded at 5,000 IDs with children_limit partial coverage. Defaults to false.
one of: true, false
Hits per page, 1–100; defaults to 30. The response echoes the page size applied by the source.
30Zero-based page number, 0–999; defaults to 0. The response echoes the page returned by the source.
0Request correlation identifier.
HTTP attempts, decoded bytes and duration for the operation, including the single shared retry.
Always included.
≥ 0
Always included.
≥ 0
Always included.
≥ 0
True when usable data is returned; inspect status and coverage for omissions.
success, partial, failed, or challenged. HTTP 200 can be partial.
one of: success, partial
Public Hacker News search, item or user URL for the request.
absolute HTTPS URL
UTC retrieval time.
Complete means this bounded page or tree was returned without known omissions. It does not imply all matching items were enumerated.
Always included.
Always included.
Always included.
Ordered source hits: objectID, title, url, author, points, num_comments, story_id, story_title, story_url, story_text, comment_text, parent_id, created_at, created_at_i, updated_at, _tags and, with includeChildren, children. Absent source fields stay absent; source nulls are preserved.
up to 100 items
Always included.
Always included.
Always included.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
Optional.
up to 5000 items
Always included.
up to 50 items
Source total match count; approximate when exhaustiveNbHits is false.
≥ 0
Zero-based page number, 0–999; defaults to 0. The response echoes the page returned by the source.
≥ 0
Source page count for the requested page size.
≥ 0
Hits per page, 1–100; defaults to 30. The response echoes the page size applied by the source.
≥ 1
Whether nbHits is exact.
No fields match.
HTTP 200 returns the success variant. Check status: partial means usable data with warnings, and failed or challenged requests carry a failure object described in Errors & responses.
| HTTP | failure.code | Meaning |
|---|---|---|
| 200 | partial | Usable data with comment_limit, depth_limit, children_limit or counts_unavailable warnings. |
| 400 | invalid_request | Missing, duplicate, malformed or unsupported parameters, including a search that selects nothing. |
| 401 | unauthorized | Missing or invalid worker API key. |
| 404 | not_found | The source reports a missing item or user. |
| 429 | upstream_rate_limited | Source throttling; no automatic retry. |
| 502 | upstream_challenged | Source rejected the unauthenticated request. |
| 502 | unsupported_page | Malformed, mismatched or non-JSON source data. |
| 502 | response_too_large payload_too_complex | Response exceeded byte or parsing limits. |
| 502 | unsafe_redirect request_limit upstream_error | Bounded source retrieval could not complete. |
| 503 | busy | All worker slots are occupied. |
| 504 | timeout | Total request deadline expired. |