Skip to main content
Glama

Search stories

search_stories

Find Hacker News stories by keyword. Returns summaries ranked by Algolia relevance, providing topic-focused results from the public HN API.

Instructions

Searches Hacker News stories by keyword via the public Algolia HN API and returns summaries ranked by Algolia relevance/popularity, not exact phrase matching or HN front-page order. 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. Empty queries are rejected, no-match searches return an empty stories array, and this is the right tool for topics or phrases; use story-list tools for rankings and get_item_thread for comments on a known item.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMaximum number of stories to return. Defaults to 10; valid range is 1 to 30.
queryYesNon-empty keyword query sent verbatim to Algolia HN search; matching is Algolia token-based search, not guaranteed exact phrase matching.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
storiesYes
returnedYes
Behavior5/5

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

Discloses all relevant behavioral traits: read-only, idempotent, unauthenticated, client caching (60s), throttling (10 req/s burst 20), error handling, and behavior for empty/no-match queries. Since no annotations are provided, the description fully compensates.

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?

The description is a single paragraph but every sentence adds value. It is concise relative to the amount of information conveyed. A structured list might improve readability, but it is not overly verbose.

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 the presence of an output schema (not shown but indicated), the description does not need to explain return values. It covers input constraints, behavior, error handling, and alternative tools, making it complete for an agent to use this tool correctly.

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 coverage is 100%, so baseline 3. The description adds value by clarifying that query is sent verbatim and matching is token-based (not exact phrase), and that limit defaults to 10 with max 30. This is useful context beyond the schema descriptions.

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 action (searches by keyword), the resource (Hacker News stories via Algolia API), and the ranking method (relevance/popularity). It also distinguishes from sibling tools by noting when to use this tool versus story-list tools and get_item_thread.

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 states when to use (topics or phrases) and when not to (use story-list tools for rankings, get_item_thread for comments). Also covers edge cases (empty query rejected, no-match returns empty array), providing clear guidance.

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