# HackerNews Monitor + Auto-Tagger | Free Preview (`w4rd0g/hackernews-monitor`) Actor

Search and monitor HackerNews stories, Show HN, Ask HN, polls, jobs by keyword and date range. Auto-tag every post with your custom keyword list. For trend detection, market intel, AI launch monitoring. FREE during launch preview.

- **URL**: https://apify.com/w4rd0g/hackernews-monitor.md
- **Developed by:** [Polara Data](https://apify.com/w4rd0g) (community)
- **Categories:** Social media, AI, News
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-usage

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## HackerNews Monitor + Auto-Tagger

Search and monitor HackerNews stories, Show HN, Ask HN, polls, jobs, comments by keyword and date range. Auto-tag every post with your custom keyword list. Built on the official Algolia public API — no auth, no rate-limit headaches, full historical archive.

### What it does

- Multi-query search (run several keywords in one execution, results grouped by query)
- Filter by post type: story, comment, Show HN, Ask HN, poll, job, front_page
- Date range filter (any time window since HN inception)
- Sort by popularity (best matches) or date (newest)
- Min points / min comments thresholds
- **Auto-tag every post** with a keyword list — perfect for trend monitoring across multiple themes

### Use cases

**Tech market intelligence** — Track every Show HN launch in your category to spot competitors and adjacent products.

**AI trend detection** — Monitor "RAG", "agent", "fine-tuning" to catch emerging topics before they go mainstream.

**Founder lead-gen** — Find Ask HN posts asking for tools in your space, reach out before they buy elsewhere.

**LLM training data** — Curate high-quality HN discussions as a corpus for fine-tuning domain-specific models.

**Content marketing** — Find high-engagement HN stories (>100 points, >50 comments) for blog post inspiration.

### Input

```json
{
  "queries": ["RAG", "LLM agents", "AI infrastructure"],
  "postType": "story",
  "sortBy": "popularity",
  "dateFrom": "2026-04-01",
  "dateTo": "2026-04-29",
  "minPoints": 5,
  "minComments": 0,
  "maxResultsPerQuery": 50,
  "tagKeywords": ["RAG", "Llama", "fine-tuning", "agent", "embedding", "vector-db", "evaluation"]
}
````

| Field | Type | Default | Description |
|---|---|---|---|
| `queries` | array | required | Search keywords (one per query) |
| `postType` | enum | `story` | story / comment / show\_hn / ask\_hn / poll / job / front\_page / all |
| `sortBy` | enum | `popularity` | popularity (best matches first) or date (newest first) |
| `dateFrom` | YYYY-MM-DD | (none) | Lower date bound (inclusive) |
| `dateTo` | YYYY-MM-DD | (none) | Upper date bound (inclusive) |
| `minPoints` | int | 5 | Skip posts below this karma |
| `minComments` | int | 0 | Skip posts below this comment count |
| `maxResultsPerQuery` | int (1-1000) | 50 | Cap per query |
| `tagKeywords` | array | \[] | Keywords auto-tagged on title |

### Output

One dataset item per matching post:

```json
{
  "query": "RAG",
  "objectID": "47955083",
  "type": "story",
  "title": "Production RAG: what I learned from processing 5M+ documents",
  "url": "https://example.com/blog/rag-lessons",
  "hnUrl": "https://news.ycombinator.com/item?id=47955083",
  "author": "user1",
  "points": 551,
  "numComments": 114,
  "createdAt": "2026-04-15T13:42:00.000Z",
  "createdAtEpoch": 1745000000,
  "storyId": null,
  "tags": ["RAG", "evaluation"]
}
```

### Pricing

**Currently FREE** during the launch preview — no per-result charges, no monthly cap.

When paid pricing rolls out (notice will be posted at least 14 days in advance):

| Event | Price |
|---|---|
| Actor start | $0.01 (one-time per run) |
| Result item | $0.001 (per post) |

**Cost examples (post-launch)**:

- 100 posts: ~$0.11
- 1.000 posts: ~$1.01
- 10.000 posts: ~$10.01

### Limits

- Source: HackerNews Algolia public search API (no auth required)
- Coverage: full HN archive (2007 onwards)
- Rate limit: ~10 req/sec (politely paced internally with 0.3s sleep)
- Max results per query: 1.000 per run
- Comment text not included by default (use HN item URL for full thread)

### Source attribution

Data comes from the [HackerNews Algolia public API](https://hn.algolia.com/api), maintained by Algolia in partnership with Y Combinator. Subject to YC's terms.

### Author

**Polara Data** — niche scrapers for Italy, EU & global markets.

# Actor input Schema

## `queries` (type: `array`):

List of search queries. Each query gets executed independently. Example: \['RAG', 'LLM agents', 'Show HN open source'].

## `postType` (type: `string`):

Limit to specific post type.

## `sortBy` (type: `string`):

popularity = best matches first. date = newest first.

## `dateFrom` (type: `string`):

Filter posts created on/after this date. Empty = no lower bound.

## `dateTo` (type: `string`):

Filter posts created on/before this date. Empty = no upper bound.

## `minPoints` (type: `integer`):

Skip posts below this karma threshold. 0 = no filter.

## `minComments` (type: `integer`):

Skip posts below this comment count. 0 = no filter.

## `maxResultsPerQuery` (type: `integer`):

Cap on results returned per query. Higher = slower.

## `tagKeywords` (type: `array`):

Each post is tagged with keywords from this list whose terms appear in the title (case-insensitive).

## Actor input object example

```json
{
  "queries": [
    "RAG",
    "LLM agents",
    "AI infrastructure"
  ],
  "postType": "story",
  "sortBy": "popularity",
  "minPoints": 5,
  "minComments": 0,
  "maxResultsPerQuery": 50,
  "tagKeywords": [
    "RAG",
    "Llama",
    "fine-tuning",
    "agent",
    "embedding",
    "vector-db",
    "evaluation"
  ]
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "queries": [
        "RAG",
        "LLM agents",
        "AI infrastructure"
    ],
    "tagKeywords": [
        "RAG",
        "Llama",
        "fine-tuning",
        "agent",
        "embedding",
        "vector-db",
        "evaluation"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("w4rd0g/hackernews-monitor").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "queries": [
        "RAG",
        "LLM agents",
        "AI infrastructure",
    ],
    "tagKeywords": [
        "RAG",
        "Llama",
        "fine-tuning",
        "agent",
        "embedding",
        "vector-db",
        "evaluation",
    ],
}

# Run the Actor and wait for it to finish
run = client.actor("w4rd0g/hackernews-monitor").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "queries": [
    "RAG",
    "LLM agents",
    "AI infrastructure"
  ],
  "tagKeywords": [
    "RAG",
    "Llama",
    "fine-tuning",
    "agent",
    "embedding",
    "vector-db",
    "evaluation"
  ]
}' |
apify call w4rd0g/hackernews-monitor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=w4rd0g/hackernews-monitor",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "HackerNews Monitor + Auto-Tagger | Free Preview",
        "description": "Search and monitor HackerNews stories, Show HN, Ask HN, polls, jobs by keyword and date range. Auto-tag every post with your custom keyword list. For trend detection, market intel, AI launch monitoring. FREE during launch preview.",
        "version": "0.1",
        "x-build-id": "C2nZsQIrR6XN0RDLE"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/w4rd0g~hackernews-monitor/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-w4rd0g-hackernews-monitor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/w4rd0g~hackernews-monitor/runs": {
            "post": {
                "operationId": "runs-sync-w4rd0g-hackernews-monitor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/w4rd0g~hackernews-monitor/run-sync": {
            "post": {
                "operationId": "run-sync-w4rd0g-hackernews-monitor",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "queries"
                ],
                "properties": {
                    "queries": {
                        "title": "Search queries",
                        "type": "array",
                        "description": "List of search queries. Each query gets executed independently. Example: ['RAG', 'LLM agents', 'Show HN open source'].",
                        "items": {
                            "type": "string"
                        }
                    },
                    "postType": {
                        "title": "Post type",
                        "enum": [
                            "story",
                            "comment",
                            "poll",
                            "job",
                            "show_hn",
                            "ask_hn",
                            "front_page",
                            "all"
                        ],
                        "type": "string",
                        "description": "Limit to specific post type.",
                        "default": "story"
                    },
                    "sortBy": {
                        "title": "Sort by",
                        "enum": [
                            "popularity",
                            "date"
                        ],
                        "type": "string",
                        "description": "popularity = best matches first. date = newest first.",
                        "default": "popularity"
                    },
                    "dateFrom": {
                        "title": "Date from (YYYY-MM-DD)",
                        "type": "string",
                        "description": "Filter posts created on/after this date. Empty = no lower bound."
                    },
                    "dateTo": {
                        "title": "Date to (YYYY-MM-DD)",
                        "type": "string",
                        "description": "Filter posts created on/before this date. Empty = no upper bound."
                    },
                    "minPoints": {
                        "title": "Min points",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Skip posts below this karma threshold. 0 = no filter.",
                        "default": 5
                    },
                    "minComments": {
                        "title": "Min comments",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Skip posts below this comment count. 0 = no filter.",
                        "default": 0
                    },
                    "maxResultsPerQuery": {
                        "title": "Max results per query",
                        "minimum": 1,
                        "maximum": 1000,
                        "type": "integer",
                        "description": "Cap on results returned per query. Higher = slower.",
                        "default": 50
                    },
                    "tagKeywords": {
                        "title": "Auto-tag keywords",
                        "type": "array",
                        "description": "Each post is tagged with keywords from this list whose terms appear in the title (case-insensitive).",
                        "items": {
                            "type": "string"
                        }
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
