hackernews-frontpage
Scrapes the Hacker News front page and returns the top 30 stories as JSON: rank, title, link, points and comment count.
- Kind
- Skill
- Works with
- Claude Code
- Source
- garrytan/gstack @ 01593aa67c94
- Path
- browser-skills/hackernews-frontpage/SKILL.md
- Jobs
- Automation
- Topics
- Web research, Creative writing
Credit
- Made by
- garrytan
- Original
- github.com/garrytan/gstack/blob/01593aa67c94780528e8f5121e473…
- License
- MIT
Listed by Skill Manifest; not made by us.
InstallCopy it from the source repository, or sign in and let the assistant adapt it for your project.
Install factsScanned 3 Nov 2026
- Adds
- .claude/skills/hackernews-frontpage/ (the skill folder)
- 4 other files in the folder: _lib/browse-client.ts, fixtures/hn-2026-04-26.html, script.test.ts, script.ts
- Runs scripts
- Yes
- _lib/browse-client.ts
- script.test.ts
- script.ts
- script file in the folder (_lib/browse-client.ts)
- Uses the network
- Yes
- HTTP client calls (_lib/browse-client.ts)
- Needs secrets
- Yes
- GSTACK_SKILL_TOKEN
- Reads environment variables
- GSTACK_PORT
- GSTACK_SKILL_TOKEN
- BROWSE_STATE_FILE
- BROWSE_TAB
- Calls other skills
- /command
- /title
- /head
- /span
- /div
- /center
- and 4 more
- Value without its scripts
- High
- The main file never tells the agent to run a bundled script, so the text works without them.
- _lib/browse-client.ts: browse-client — canonical SDK that browser-skill scripts import to drive the
- script.test.ts: hackernews-frontpage script tests — exercise parseStoriesFromHtml against
- script.ts: hackernews-frontpage — scrape the HN front page and emit JSON.
- Source revision
- 01593aa67c94
- Licence
- MIT
- Last activity
- 27 Nov 2026
- Source changed after the scan
- Yes
- Last push 27 Nov 2026, scanned 3 Nov 2026; read it again before you rely on this scan
- Review
- Reviewed
Found by a static scan of the stored text; nothing is run. “None found” is not a guarantee, so read what you install before you run it.
# Hacker News front-page scraper
Scrapes the Hacker News (`news.ycombinator.com`) front page and returns the
top 30 stories as JSON. Each story has its rank, title, link URL, point count,
and comment count.
## Usage
```
$ $B skill run hackernews-frontpage
{
"stories": [
{ "rank": 1, "title": "...", "url": "...", "points": 412, "comments": 87 },
...
],
"count": 30
}
```
## How it works
1. Navigates to `https://news.ycombinator.com` via the daemon.
2. Reads the page HTML.
3. Parses each story row (HN's stable `tr.athing` structure) into a typed
`Story` record.
4. Emits a single JSON document on stdout.
## Why this is the reference skill
`hackernews-frontpage` is the smallest interesting browser-skill: no auth,
stable HTML, deterministic output, file-fixture-friendly. Every Phase 1
component (SDK, scoped tokens, three-tier lookup, spawn lifecycle) is
exercised by `$B skill run hackernews-frontpage` and the bundled
`script.test.ts`.
When the HN HTML rotates and our selectors break, the test fails against the
captured fixture before users notice. That's the point.