Search
1 credit/v1/hackernews/searchStories matching a query: title, link, author, points, comment count, and post time. Optional tags can widen results to comments and other item types.
query, tags, numericFilters, hitsPerPage, page
Fetch public Hacker News search hits, stories, comment trees, and profiles as structured JSON with one SocialCrawl API key. Same Post, Comment, and Author schema as every other platform. Reads are priced in credits.
4 active endpoints
Four live read endpoints for public Hacker News data. Keyword search, single stories, nested comment trees, and user profiles. Data API only. No voting, no submission, no private accounts.
/v1/hackernews/searchStories matching a query: title, link, author, points, comment count, and post time. Optional tags can widen results to comments and other item types.
query, tags, numericFilters, hitsPerPage, page
/v1/hackernews/storyOne story by id: title, link, author, points, comment count, and publish time. Discussion comes from story/comments.
id
/v1/hackernews/story/commentsComment tree for one story: id, author, text, points, time posted, and nested replies.
id
/v1/hackernews/profilePublic user profile: id, username, bio, karma, and account creation date. Follower and post counts are empty because HN does not expose them.
handle
Returns Hacker News stories matching a query, each with title, link, author, points, comment count, and post time. Tags can widen it to comments.
Use it to find discussions by keyword, then pass a story id to the story endpoint for its details or its comments.
query · Free-text search term.
$ curl https://www.socialcrawl.dev/v1/hackernews/search?query=claude+code \
-H "x-api-key: sc_YOUR_API_KEY"// Running this live needs your own API key — hit "Try it" to see an example responseHacker News is a normal SocialCrawl social surface. You call GET /v1/hackernews/… with an API key, spend credits on live misses, and get a single JSON envelope back. No HN account. No second SDK.
Send your key in the x-api-key header. No Hacker News credentials. The same key works across the SocialCrawl catalog.
All Hacker News routes are GET. Pass query, id, tags, page, and filters as query strings. We validate formats before charging.
Every Hacker News read costs 1 credit on a live miss. Cache hits cost 0. Empty or hard failures refund.
Every response is the same shape: success, data, credits_used, credits_remaining, request_id, cached. Search pages carry pagination fields when more hits remain.
Most products search first, open a story, then expand comments only when the thread matters.
GET /v1/hackernews/search?query=…&tags=storyPostList of matching stories with points and comment counts
Find discussions by keyword before you know story ids.
GET /v1/hackernews/story?id=…Full Post for one story id
Search titles are not enough when you need the story record.
GET /v1/hackernews/story/comments?id=…CommentList with nested replies[]
Expand the thread only when the discussion is the product job.
GET /v1/hackernews/profile?handle=…Author-shaped user: karma, bio, created date
Resolve who posted once you care about the author.
GET /v1/hackernews/search
?query=launch+api
&tags=story
Host: www.socialcrawl.dev
x-api-key: sc_your_api_key_here
# deepen a story
GET /v1/hackernews/story?id=8863
GET /v1/hackernews/story/comments?id=8863{
"success": true,
"data": {
"items": [
{
"post": {
"id": "8863",
"url": "https://news.ycombinator.com/item?id=8863",
"content": { "text": "Example title" },
"engagement": { "likes": 1200, "comments": 318 },
"ext": {
"points": 1200,
"author": "pg"
}
}
}
]
},
"credits_used": 1,
"credits_remaining": 9999,
"request_id": "req_…",
"cached": false
}Field names match the rest of SocialCrawl where archetypes align. Stories and comments use the same leaves as other platforms.
id, username, bio, url, ext (karma, created_at); followers and post counts empty on HN
items[].post with id, url, content.text (title), engagement (points, comments), author, published_at, ext
items[] with author, content.text, engagement, published_at, replies[] for nested discussion
raw Algolia-style hits in list form: objectID, title, url, author, points, num_comments, tags
Same request lifecycle as every other /v1 platform endpoint. Hacker News is not a sidecar.
Next.js catch-all routes into the Hono social API. We mint a request_id, authenticate the key, then enforce rate limit (600/min) and concurrency (50 in flight per key).
Registry lookup finds hackernews/search (or story, comments, profile). Required params run first. Invalid input returns 400 with no charge. Valid calls debit 1 credit atomically before upstream work.
A deterministic cache key is built from platform + resource + params. Hit: return immediately, credits_used = 0. Miss: HN Algolia public API via the Hacker News fetcher. Retries on 5xx/network with a circuit breaker if the source is unhealthy.
Upstream JSON is mapped to Author / Post / PostList / CommentList where field maps apply, validated against the canonical Zod schema, then wrapped in the success envelope and logged for billing audit.
Billing rules that matter in production
Hacker News is public-read discussion data. We normalize it into the SocialCrawl schema so your code does not learn Algolia-only hit shapes.
Public stories, comments, and user profiles. Read-only surface for research, monitoring, and product jobs. No voting and no submission.
Public HN Algolia API (hn.algolia.com) behind the SocialCrawl gateway. The platform fetcher composes search and item URLs from query params and ids.
A unified JSON envelope: success, data, credits_used, request_id, cached. Stories become Post objects. Comments share CommentList leaves with nested replies.
No write endpoints. No private messages. No follower graph (HN does not expose one). Prefer the registry docs for the live inventory.
The jobs this API is most often used for.
Tech discussion search and thread monitoring
Callers concentrate on keyword search, story detail, and story to comments chains. Profiles show up when author context matters. HN search, story, nested comments, and profiles on the shared schema with credit pricing. No HN account and no second client library.
Search and story calls are typically a few seconds on live miss. Large comment trees can take longer than single-story reads.
The jobs Hacker News data is most often used for. Each one is a full recipe with the endpoint chain and pricing.
Common ways teams put this data to work, and the stack each one tends to run.
Poll search for fixed keywords. Open story plus comments when points or comment velocity jumps.
Keyword search across HN, then expand story body and comment trees for product, brand, and competitor language.
Wire search to story to comments into pipelines. Cache hits keep recurring runs cheap. Same key as the rest of SocialCrawl.
Every Hacker News route is one credit per live call. Cache hits are free.
curl "https://www.socialcrawl.dev/v1/hackernews/search?query=launch+api&tags=story" \
-H "x-api-key: sc_your_api_key_here"curl "https://www.socialcrawl.dev/v1/hackernews/story/comments?id=8863" \
-H "x-api-key: sc_your_api_key_here"Same key as the rest of the catalog
Every endpoint returns structured JSON in a unified envelope. Computed fields such as engagement rate and content category are included only where the endpoint supports them and the required source inputs are present.
Same Hacker News data, two very different paths. Auth, rate limits, schema, and cost — side by side.
| Feature | SocialCrawl | Official HN Firebase API + Algolia |
|---|---|---|
| Authentication | One x-api-key shared across 48 platforms | No key needed, but two separate APIs to learn |
| Setup | One GET request in the same envelope as your other sources | Firebase for items, Algolia for search: two clients, two response shapes |
| Rate limits | Handled upstream as part of the service | Generous but unspecified; you build your own backoff |
| Response schema | Unified data.items shape shared with Reddit, GitHub, and X | Firebase returns raw items one ID at a time; Algolia uses its own hit format |
| Pricing | 1 credit per call; 100 free credits, no card | Free |
| Data coverage | Search, story, full threaded comment tree, and profile in four calls | Full item coverage, but comment trees mean one request per comment ID |
Authentication
Setup
Rate limits
Response schema
Pricing
Data coverage
Find answers to frequently asked questions about SocialCrawl's API, pricing, and capabilities.
Contact usAsk AI about SocialCrawl