Skip to main content
Glama

Get item thread

get_item_thread

Retrieve a Hacker News item by ID and expand its nested comment tree, providing full discussion context for any valid item.

Instructions

Fetches one Hacker News item by numeric itemId and expands its nested comment tree, unlike story-list tools or search_stories which return lists without discussion context. Read-only, idempotent, and unauthenticated; the client caches GET responses in memory for 60 seconds and throttles upstream HN/Algolia requests to 10 requests/second with a burst of 20, while upstream HTTP, rate-limit, or response-shape failures are returned as tool errors. Missing root items throw a 404-style error, deleted/dead descendants are skipped, and broad branches are truncated by maxChildren; use only when you already have an item ID.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
depthNoMaximum reply nesting depth to expand. Defaults to 2; valid range is 1 to 6.
itemIdYesHacker News item ID to fetch. Must be a nonnegative integer from HN item URLs or prior tool results.
maxChildrenNoMaximum number of child comments fetched per item at each depth. Defaults to 20; valid range is 1 to 50.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
threadYes
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description fully covers traits: client caching, throttling, error handling (missing root 404, deleted/dead skipped), and truncation via maxChildren.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence is efficient but dense; could be split for readability, but it packs significant information without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no annotations and an output schema, the description covers error scenarios, caching, throttling, and constraints, making it fully informative for agent usage.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema covers all parameters (100% coverage), but the description adds behavioral context like truncation and comment tree expansion, aiding understanding beyond schema details.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool fetches one Hacker News item by ID and expands its comment tree, distinguishing it from sibling tools like story-list and search_stories.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly contrasts with alternative tools ('unlike story-list tools or search_stories') and states when to use ('only when you already have an item ID'), along with noting read-only, idempotent, unauthenticated access.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Markgatcha/universal-mcp-toolkit'

If you have feedback or need assistance with the MCP directory API, please join our Discord server