# Stack Overflow Question Monitor: New & Unanswered by Tag (`datacrate/stack-exchange-question-monitor`) Actor

Watch Stack Overflow and other Stack Exchange sites for new, active or unanswered questions by tag or keyword. Official API: score, answers, views, accepted flag, link. No author data. Delta mode returns only new questions.

- **URL**: https://apify.com/datacrate/stack-exchange-question-monitor.md
- **Developed by:** [Data Crate](https://apify.com/datacrate) (community)
- **Categories:** Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.40 / 1,000 question returneds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## Stack Overflow Question Monitor – new and unanswered Stack Exchange questions by tag or keyword

Watch **Stack Overflow** and any other **Stack Exchange** site (Server Fault, Super User, Ask Ubuntu, Mathematics and hundreds more; the API lists 365 sites including meta sites) for **new, recently active or unanswered questions** about your tags and keywords. You get one clean row per question: title, tags, score, answer count, view count, answered / accepted flags, dates and the link. Data comes from the **official Stack Exchange API (v2.3)**. No scraping, no browser, no login, no proxies.

It is built for developer-relations and support teams who want to find unanswered questions about their product, for content teams looking for what developers keep asking about a tag, and for anyone tracking mentions of a library, competitor or error message.

**Metadata only. No user data.** Every row describes a question, never a person. The actor never returns the asker's name, id, profile link, avatar or reputation, and it returns no full post bodies (an optional 280-character plain-text excerpt is available, off by default).

**First run:** press Start. The prefill (tag `apify` on Stack Overflow, 25 newest questions) costs about **$0.01** (25 questions at **$0.0005** each) and finishes in a few seconds. **Empty input also works:** you get the 25 newest questions on Stack Overflow.

### What you can do with it

- **Find unanswered questions about your product:** `tags: ["your-product"]`, `unansweredOnly: true`, schedule it daily, send the new rows to Slack or your support queue.
- **Daily alert of only new questions:** turn on `sinceLastRun`. Each run returns just the questions that appeared since the previous run with the same State name. Every row carries `isNew` and `firstSeenAt`.
- **Track keywords and competitors:** `keywords: ["playwright timeout", "crawlee"]` searches titles and bodies on the site and returns matching questions.
- **Content research:** `sort: "votes"` with `daysBack: 365` lists the most-voted recent questions for a tag, a quick view of what people struggle with.
- **Watch several sites at once:** `sites: ["stackoverflow", "serverfault", "superuser"]`.

### Input

| Field | What it does |
|---|---|
| `sites` | API site names: `stackoverflow` (default), `serverfault`, `superuser`, `askubuntu`, `math`, `stats`, `datascience`, ... A site URL such as `https://math.stackexchange.com` also works |
| `tags` | Tags to watch. Several entries are combined as OR (one API request each). Write `"a;b"` in one entry to require both tags. Empty = all new questions on the site |
| `keywords` | Search phrases (title and body, any of them). Combined with `tags` when both are set |
| `unansweredOnly` | Only questions with zero answers |
| `minScore` | Skip questions with a lower vote score |
| `daysBack`, `fromDate` | Only questions created (or, with `sort: "activity"`, active) in the last N days, or since a fixed `YYYY-MM-DD` (UTC). `fromDate` wins |
| `sort` | `creation` = newest first (default), `activity` = recently active first, `votes` = highest score first |
| `includeExcerpt` | Adds `excerpt`: the first 280 characters of the question body as plain text (code removed). Off by default |
| `sinceLastRun`, `stateKey` | Delta mode: only questions not returned by an earlier run with the same State name, and only from the period since that run. The first run returns everything and builds the baseline |
| `maxItems` | Cap on questions returned (default 25). You pay per question |
| `apiKey` | Optional free Stack Exchange API key (secret). See "Quota" below |

Example: `{ "sites": ["stackoverflow"], "tags": ["apify"], "maxItems": 25 }`

Unanswered-question alert, delta mode: `{ "tags": ["your-product"], "unansweredOnly": true, "sinceLastRun": true, "stateKey": "support-watch", "maxItems": 200 }`

### Output

```json
{
  "site": "stackoverflow",
  "questionId": 79677814,
  "title": "Invalid JSON error using n8n to create a leadscraper",
  "tags": ["artificial-intelligence", "openai-api", "apify", "n8n"],
  "score": 2,
  "answerCount": 1,
  "viewCount": 301,
  "isAnswered": true,
  "hasAcceptedAnswer": false,
  "isClosed": false,
  "createdAt": "2025-06-24T15:11:28.000Z",
  "lastActivityAt": "2025-08-21T13:10:13.000Z",
  "url": "https://stackoverflow.com/questions/79677814/invalid-json-error-using-n8n-to-create-a-leadscraper",
  "isNew": null,
  "firstSeenAt": "2026-11-19T19:35:53.612Z",
  "source": "Stack Exchange Network",
  "license": "CC BY-SA 4.0",
  "attribution": "Source: Stack Exchange Network, CC BY-SA 4.0. Original question: https://stackoverflow.com/questions/79677814/invalid-json-error-using-n8n-to-create-a-leadscraper"
}
```

Notes on fields:

- `isAnswered` is the site's own flag (the question has an accepted answer or an answer with a positive score). `hasAcceptedAnswer` is true only when the asker accepted an answer. `answerCount` is the number of answers.
- `unansweredOnly` means `answerCount = 0`.
- `isNew` is `null` until a baseline exists for your State name, then `true` or `false`.
- `source`, `license` and `attribution` are on **every** row, together with `url` (see "Terms and licence").
- `excerpt` appears only when `includeExcerpt` is on.
- Every run also saves a `SUMMARY` record (requests used, quota left, errors) in the run's key-value store.

### Terms and licence

Data is read through the official, documented **Stack Exchange API v2.3** (`api.stackexchange.com`), the programmatic interface the network provides. We read these pages on 2026-11-19:

- [Stack Exchange API Terms of Use](https://stackoverflow.com/legal/api-terms-of-use): the API lets you "programmatically query and connect to the Stack Exchange Network". Its attribution rule: "All Applications must ensure they visually indicate that the Stack Exchange Network is the source of the content provided through the API Services", and for applications without web browsing "simple text versions of URLs (instead of hyperlinks) will be sufficient". Every row therefore carries `source` and `url`.
- [Public Network Terms of Service](https://stackoverflow.com/legal/terms-of-service/public): the restriction on copying public Network content explicitly excludes "Subscriber Content or content made available via the Stack Overflow API". User contributions are licensed under **CC BY-SA** (the API returns the exact version per question as `content_license`, for example "CC BY-SA 4.0"; we pass it through as `license`).
- [API throttle documentation](https://api.stackexchange.com/docs/throttle): a dynamic throttle applies per method; "If an application receives a response with the backoff field set, it must wait that many seconds before hitting the same method again", and no application should make semantically identical requests more than once a minute. This actor honours every `backoff`, reads `quota_remaining` from each response, identifies itself as `datacrate-actor/1.0`, and sends fewer than 3 requests per second (the API's hard limit is 30 per second per IP).
- `api.stackexchange.com/robots.txt` does not exist (the API answers HTTP 400), so there is no robots file to apply. The actor does not fetch any HTML page of the network.

**Attribution if you republish.** Questions are licensed CC BY-SA, which requires credit to the authors and a link to the original. This dataset gives you the title, the question link and the license, but deliberately no author names. If you publish a question title or excerpt, link to `url` (the original page shows its authors and history) and keep the CC BY-SA notice. Share-alike applies to any adapted content you publish. This is not legal advice.

**Personal data.** The `owner` object returned by the API (display name, user id, profile link, avatar, reputation) is never read into a row. Excerpts, if you turn them on, have e-mail addresses and phone numbers removed. Question titles are written by users and can occasionally mention a person or company; treat them accordingly.

Not affiliated with or endorsed by Stack Exchange, Inc. "Stack Overflow" and "Stack Exchange" are their trademarks, used here only to identify the data source.

### Quota: with and without an API key

The Stack Exchange API limits how much each caller can read:

- **Without a key**, all applications on the same IP address share one daily quota (the API reports it as `quota_max`, about **300 requests** per IP per day when we tested on 2026-11-19). On Apify's shared IPs other users may have used part of it. A typical run needs 1 to 3 requests (100 questions per request), so the empty and prefill runs normally work without a key, but a busy shared IP can run out.
- **With a free API key** (register an app at [stackapps.com](https://stackapps.com/apps/oauth/register), no review needed for read-only use), your actor gets its own quota of **10,000 requests per day**. Paste the key into `apiKey`; it is stored as a secret and never written to the log or the dataset. A key is recommended for scheduled monitoring.

If the shared quota is exhausted and nothing could be fetched, the run fails with a clear message that tells you to add a key. If some questions were already fetched, you get them and a warning in the log. The run summary always shows `quotaRemaining`.

### FAQ

**How fresh is the data?** The data is as fresh as the Stack Exchange API. Note that the API caches identical requests for about a minute (see its throttle documentation).

**What does "new" mean in delta mode?** A question is new when it was not returned by an earlier run with the same State name and it appeared after that run (created after it, or, with `sort: "activity"`, active after it). The first run returns everything it finds and creates the baseline, so set `maxItems` high enough on the first run. Every run records the questions it returns under its State name (also runs with `sinceLastRun` off), so use a separate State name per watchlist. If a run is cut short by the API quota, the baseline time is not advanced, so the next delta run covers the gap. State is kept for 90 days.

**Can I get answers, comments or user profiles?** No. This actor returns questions only, without user data, by design.

**Can I get full question text?** No. Only the optional 280-character excerpt. Use the `url` to read the full post.

**How do I watch several tags?** Put each tag in its own entry of `tags`. They are combined as OR. To require two tags on the same question, write them in one entry, separated by a semicolon, for example `"python;pandas"`.

**Which site names work?** The API site names, e.g. `stackoverflow`, `serverfault`, `superuser`, `askubuntu`, `math`, `stats`, `unix`, `softwareengineering`. An unknown name returns a clear error in the log.

**What happens if the API throttles me?** The actor waits as the API asks (`backoff`), retries short waits, and stops cleanly if the shared quota is gone for the day. See "Quota" above.

### Integrations

- **Schedule** the actor (for example every morning) with `sinceLastRun: true` for a feed of new questions.
- **Webhook** on run success to push new rows to Slack, Discord, e-mail, Zapier, Make or n8n.
- **API and MCP:** call the actor from the Apify API or use it as a tool in AI agents through the Apify MCP server.
- Export the dataset as JSON, CSV or Excel from the Console.

### Pricing

Pay per result: **$0.0005 per question** ($0.50 per 1,000), no start fee. Higher Apify plans get lower per-question prices (up to 20% lower). Set `maxItems` to cap spend.

**What does one run cost?** The prefill (25 questions) is about $0.01. 100 questions are $0.05, 1,000 are $0.50. A daily unanswered-question alert that returns 10 new questions a day costs about $0.15 a month.

**Do I pay for questions that are filtered out or skipped by delta mode?** No. You are charged only for rows that are returned to the dataset.

**Do I pay for the API key?** No. The key is free and the API does not charge.

### Related actors

More DataCrate data actors: [apify.com/datacrate](https://apify.com/datacrate).

### Changelog

- **1.0** First version: Stack Overflow and other Stack Exchange sites, tag and keyword monitoring, unanswered filter, minimum score, date window, three sort orders, optional excerpt, delta mode, optional API key, `backoff` and quota handling, source and license on every row.

# Actor input Schema

## `sites` (type: `array`):

Stack Exchange sites to watch, by API name: stackoverflow, serverfault, superuser, askubuntu, math, stats, datascience, and so on. Full site URLs also work.

## `tags` (type: `array`):

Watch these tags (one entry = one tag; several entries are combined as OR). Write "a;b" in one entry to require both tags. Leave empty to watch all new questions on the site.

## `keywords` (type: `array`):

Search phrases (title and body search, any of them). Combined with the tags above when both are set. Example: "playwright timeout".

## `unansweredOnly` (type: `boolean`):

Only questions with zero answers.

## `minScore` (type: `integer`):

Skip questions with a lower vote score. Leave empty for no minimum.

## `daysBack` (type: `integer`):

Only questions created (or, with sort = activity, active) in the last N days. Leave empty for no date limit. Ignored when From date is set.

## `fromDate` (type: `string`):

Optional fixed start date, YYYY-MM-DD (UTC). Overrides Days back.

## `sort` (type: `string`):

creation = newest questions first, activity = most recently active first, votes = highest score first.

## `includeExcerpt` (type: `boolean`):

Adds a plain-text excerpt of the question body, cut to 280 characters (code blocks removed). Off by default; full bodies are never returned.

## `sinceLastRun` (type: `boolean`):

Return only questions not returned by a previous run with the same State name. The first run returns everything and builds the baseline. Every row carries isNew and firstSeenAt.

## `stateKey` (type: `string`):

Name of the saved list of already-returned questions. Use a different name for each watchlist.

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

Stop after this many questions. You are charged per question returned.

## `apiKey` (type: `string`):

Optional. Without a key the Stack Exchange API gives all apps on the same IP address one shared daily quota (about 300 requests). A free key from stackapps.com gives you your own 10,000 requests a day. Recommended for scheduled monitoring.

## Actor input object example

```json
{
  "sites": [
    "stackoverflow"
  ],
  "tags": [
    "apify"
  ],
  "keywords": [],
  "unansweredOnly": false,
  "sort": "creation",
  "includeExcerpt": false,
  "sinceLastRun": false,
  "stateKey": "default",
  "maxItems": 25
}
```

# Actor output Schema

## `results` (type: `string`):

One row per Stack Exchange question (default dataset items).

# 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 = {
    "sites": [
        "stackoverflow"
    ],
    "tags": [
        "apify"
    ],
    "maxItems": 25
};

// Run the Actor and wait for it to finish
const run = await client.actor("datacrate/stack-exchange-question-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 = {
    "sites": ["stackoverflow"],
    "tags": ["apify"],
    "maxItems": 25,
}

# Run the Actor and wait for it to finish
run = client.actor("datacrate/stack-exchange-question-monitor").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 '{
  "sites": [
    "stackoverflow"
  ],
  "tags": [
    "apify"
  ],
  "maxItems": 25
}' |
apify call datacrate/stack-exchange-question-monitor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,datacrate/stack-exchange-question-monitor"
        }
    }
}
```

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/FpZwZeaDxDRb93O1N/builds/qYfXc1JsSeus8rkTT/openapi.json
