A minimal Model Context Protocol server in TypeScript that wraps the Hacker News API.
Three tools with complete schemas and reasonable descriptions. All tools follow verb_noun naming (hn_top_stories, hn_get_story, hn_search). Descriptions are 100-180 chars, within the 10-1024 baseline. Input parameters have types and descriptions. However, output schemas are not documented, LLMs cannot predict response structure. Error handling is present but generic ('HN API unavailable'). No parameter constraints beyond min/max on numeric fields. Missing enum validation for search query patterns.
Fetch a single Hacker News story by id. Returns title, author, score, body, and URL. Comments, jobs, polls, and pollopts are rejected — use Hacker News directly for those.
Full-text search HN stories via the Algolia HN API. Returns up to `limit` matching stories.
Fetch the current top stories from the Hacker News front page. Returns title, author, score, comment count, and URL for each.
Output schemas not documented. LLMs cannot predict response structure (fields, types, nesting). Responses are free-text strings; no structured object definitions provided.
Error messages are generic ('HN API unavailable: <message>'). Do not guide LLM on recovery actions (e.g., 'retry in 30s', 'try a different query'). Missing error classification (retryable vs fatal).
hn_search 'query' parameter lacks format constraints. Description says 'minLength:1, maxLength:200' but no guidance on valid characters, special operators, or examples. LLMs may pass malformed queries.
hn_get_story rejects comments/jobs/polls but does not offer alternative tools. Error message 'use Hacker News directly' is not actionable for an LLM. Should suggest hn_search or document limitations upfront.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 57 | 2026-07-28+ | v2 |
No pagination support. hn_top_stories returns up to 50 items; hn_search up to 20. No offset/cursor or total_count in response. Large result sets could exhaust context window.