search_hn
Pack: hackernews · Endpoint: https://gateway.pipeworx.io/hackernews/mcp
Search Hacker News for stories, comments, and users by keyword. Returns titles, URLs, scores, author names, and timestamps.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
query | string | yes | Search query string |
tags | string | no | Content type filter: story, comment, ask_hn, or show_hn (default: story) |
per_page | number | no | Number of results to return (default: 10) |
Example call
Arguments
{
"query": "artificial intelligence"
}
curl
curl -X POST https://gateway.pipeworx.io/hackernews/mcp \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"search_hn","arguments":{"query":"artificial intelligence"}}}'
TypeScript (@pipeworx/sdk)
import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();
const result = await pipeworx.call('search_hn', {
"query": "artificial intelligence"
});
More examples
{
"query": "startup funding",
"tags": "story",
"per_page": 20
}
Response shape
Always returns: query, tags, count, results
| Field | Type | Description |
|---|---|---|
query | string | The search query string used |
tags | string | Content type filter applied |
count | number | Number of results returned |
results | array | Array of search result items |
Full JSON Schema
{
"type": "object",
"properties": {
"query": {
"type": "string",
"description": "The search query string used"
},
"tags": {
"type": "string",
"description": "Content type filter applied"
},
"count": {
"type": "number",
"description": "Number of results returned"
},
"results": {
"type": "array",
"description": "Array of search result items",
"items": {
"type": "object",
"properties": {
"objectID": {
"type": "string",
"description": "Unique identifier for the HN item"
},
"title": {
"type": [
"string",
"null"
],
"description": "Story title"
},
"url": {
"type": [
"string",
"null"
],
"description": "Story URL"
},
"author": {
"type": [
"string",
"null"
],
"description": "Author username"
},
"points": {
"type": [
"number",
"null"
],
"description": "Story points/score"
},
"num_comments": {
"type": [
"number",
"null"
],
"description": "Number of comments"
},
"created_at": {
"type": [
"string",
"null"
],
"description": "Creation timestamp"
}
},
"required": [
"objectID"
]
}
}
},
"required": [
"query",
"tags",
"count",
"results"
]
}
Connect
Add this to your MCP client config, or use one-click install buttons:
{
"mcpServers": {
"hackernews": {
"url": "https://gateway.pipeworx.io/hackernews/mcp"
}
}
}
See Getting Started for client-specific install steps.