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. Each successful request costs 1 account credit, including partial results. Failed requests cost 0 credits.
Request
- Base URL: https://api.scrapeatlas.com
- URL: https://api.scrapeatlas.com/v1/hackernews/search
- Auth: API key in header x-api-key
Query parameters
Free-text search term, 1–500 characters. Optional when tags or numericFilters is supplied. Quoted phrases and -exclusions are supported by the source index.
Comma-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.
Comma-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.
relevance (default) ranks by the source relevance score; date returns the newest matching items first.
false matches the query exactly; the source tolerates typos by default. Defaults to the source setting.
Comma-separated attributes to match against: title, url, author, story_text or comment_text. At most 5. Defaults to all of them.
true adds the source children ID list to each hit, bounded at 5,000 IDs with children_limit partial coverage. Defaults to false.
Hits per page, 1–100; defaults to 30. The response echoes the page size applied by the source.
Zero-based page number, 0–999; defaults to 0. The response echoes the page returned by the source.
Response
Inspect the response status and failure or coverage fields.
Changes
No recorded changes to this operation across all 1 revision of this API.