# Hacker News Jobs Scraper (`w3crawler/hackernews-jobs-scraper`) Actor

Scrape the Hacker News job board - the famous 'Who is Hiring' startup job posts on news.ycombinator.com. Fetches live job listings posted by startups and tech companies via the official HN Firebase API. No authentication required.

- **URL**: https://apify.com/w3crawler/hackernews-jobs-scraper.md
- **Developed by:** [w3crawler](https://apify.com/w3crawler) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.99 / 1,000 jobs

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Hacker News Who Is Hiring Scraper

CSV rank: **3966**. Store listing: [trisert/hn-who-is-hiring](https://apify.com/trisert/hn-who-is-hiring).

This Actor reads the official public Hacker News Firebase `jobstories` feed and emits one normalized record per complete public job post. It does not fetch external company career pages, contact private endpoints, use a proxy, log in, or bypass access controls.

### Output

You can download the dataset in various formats such as JSON, HTML, CSV, or Excel.

Job rows use `recordType: "hn_job_listing"` and a stable `recordId`. They include the stable HN item ID, title, company name, role title, YC batch when present, submitting author, timestamps, HTTPS HN URL, an optional HTTPS external job URL, normalized post text, location/work-arrangement signals, compensation text, public contact emails found in the post, score, comment count, and bounded raw HTML. Failures and clean empty results never create diagnostic or placeholder dataset rows.

The exact `OUTPUT` key-value record reports canonical `status`, `runStatus`, and `dataStatus` values plus feed size, detail requests, source-backed emitted jobs, skipped items, numeric diagnostic counts, duplicates, and the official-source policy.

### Input and limits

`startUrls` accepts exactly `https://hacker-news.firebaseio.com/v0/jobstories.json`. `maxItems`, `requestDelayMs`, `timeoutSecs`, `maxResponseBytes`, `maxTextChars`, and `includeRawText` provide bounded work and storage. Invalid explicit values produce a failed run summary without writing a dataset row. The current feed already contains job item IDs; no pagination or external job-site crawling is required.

### Local verification

```text
npm ci
npm test
npm run lint
apify validate-schema
apify run --purge --entrypoint src/main.js --input '{"startUrls":[{"url":"https://hacker-news.firebaseio.com/v0/jobstories.json"}],"maxItems":5,"requestDelayMs":100,"timeoutSecs":10}'
npm run validate
```

A clean empty feed succeeds with `NO_RESULTS`; source-backed jobs plus a later failure succeed with `PARTIAL`; a request failure with no saved job records fails. Only the official public Firebase feed and public HN item endpoints are requested. External job pages are never fetched; non-HTTPS external links are omitted from output.

QA validated locally and on Apify Cloud with a bounded live job-feed sample. Generated by Codex with GPT-5.6 Sol.

# Actor input Schema

## `startUrls` (type: `array`):

Use the official Hacker News Firebase jobstories endpoint. Other sites and external job pages are not fetched.

## `maxItems` (type: `integer`):

Maximum complete job records emitted from the bounded feed scan.

## `requestDelayMs` (type: `integer`):

Polite delay between official Firebase item requests.

## `timeoutSecs` (type: `integer`):

Maximum time allowed for each official Firebase request.

## `maxResponseBytes` (type: `integer`):

Bound each official Firebase JSON response.

## `maxTextChars` (type: `integer`):

Bound normalized and raw HN job-post text retained per record.

## `includeRawText` (type: `boolean`):

Retain a bounded copy of the public HN job body HTML for provenance.

## Actor input object example

```json
{
  "startUrls": [
    {
      "url": "https://hacker-news.firebaseio.com/v0/jobstories.json"
    }
  ],
  "maxItems": 25,
  "requestDelayMs": 250,
  "timeoutSecs": 30,
  "maxResponseBytes": 5000000,
  "maxTextChars": 20000,
  "includeRawText": true
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

## `summary` (type: `string`):

No description

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("w3crawler/hackernews-jobs-scraper").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 = {}

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

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

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

```

## CLI example

```bash
echo '{}' |
apify call w3crawler/hackernews-jobs-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,w3crawler/hackernews-jobs-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/tZcLXKvtP9394kmHE/builds/n26ZK5B3Aoxr847Yy/openapi.json
