# Outbreak Watch — WHO Disease Outbreak Alerts (`scrapeai/outbreak-watch`) Actor

Watch WHO's official Disease Outbreak News feed and get alerted the moment a new international outbreak (Ebola, cholera, mpox, avian flu...) is published - optionally filtered to diseases, countries, or regions you care about. Only new alerts are reported after the first baseline check.

- **URL**: https://apify.com/scrapeai/outbreak-watch.md
- **Developed by:** [ScrapeAI](https://apify.com/scrapeai) (community)
- **Categories:** News
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 0.0% runs succeeded, 0 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/actors/running/actors-in-store.md#pay-per-usage

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

## Outbreak Watch — WHO Disease Outbreak Alerts

### What does this Actor do?

Reads the World Health Organization's official **Disease Outbreak News (DON)** feed and returns one record per international outbreak alert. Each run can be filtered by disease, country, region or keyword, and after the first baseline run it reports only alerts that were not seen before.

The Actor calls the WHO public API directly (`https://www.who.int/api/news/diseaseoutbreaknews`). It does not log in, does not use a third-party Actor and does not need a proxy.

### Why use this Actor?

- Official WHO source, updated as soon as a new DON is published.
- Disease, country, region and keyword filters with region aliases (e.g. `Africa` also matches `African Region`).
- Built-in new-alert tracking: the first run establishes a baseline, later runs return only new IDs.
- Clean, flat records ready for schedules, alerts, dashboards and datasets.
- `RUN_SUMMARY` reports how many alerts were fetched, matched, new and returned.

### Input

| Field | Type | Default | Description |
| --- | --- | --- | --- |
| `diseases` | array | `[]` | Terms matched against the title and summary, e.g. `Ebola`, `cholera`, `mpox`, `H5N1` |
| `countries` | array | `[]` | Countries or places, e.g. `Democratic Republic of the Congo` |
| `regions` | array | `[]` | WHO regions; aliases are resolved (`Africa` → `African Region`) |
| `keywords` | string | — | Free-text phrase that must appear in the title or summary |
| `lookbackDays` | integer | 30 | Feed window in days (1–365) |
| `maxResults` | integer | 25 | Maximum alerts returned per run (1–200) |
| `onlyNew` | boolean | true | After the baseline run, return only unseen alerts |
| `includeSummary` | boolean | true | Include the summary text (max 2000 chars) |
| `resetState` | boolean | false | Clear the seen-alert list and treat this run as a new baseline |

Example:

```json
{
  "diseases": ["Ebola", "cholera", "mpox"],
  "regions": ["Africa"],
  "lookbackDays": 60,
  "maxResults": 25,
  "onlyNew": true
}
```

#### Filter semantics

- Terms inside one array are OR-ed; different arrays are AND-ed.
- Matching is case-insensitive text matching on the alert title, summary and overview.
- Regional aliases: `Africa` ↔ `African Region`, `Americas` ↔ `Region of the Americas`, `Europe` ↔ `European Region`, `Asia`/`Oceania` ↔ `Western Pacific`/`South-East Asia`, `Middle East` ↔ `Eastern Mediterranean`.

### How new-alert tracking works

- The Actor stores seen alert IDs under `ALERT_STATE` in the named key-value store `outbreak-watch-state` (newest 2000 IDs), so the state survives across runs.
- **First run (baseline):** no state exists, so every matching alert inside `lookbackDays` is returned with `isNew: false`, and all fetched IDs are stored.
- **Later runs:** only IDs that are not in the state are returned, with `isNew: true`. An empty dataset means "no new alerts", and the run still finishes as SUCCEEDED.
- **`resetState: true`:** ignores the stored IDs for this run and rebuilds the baseline.

### Output

| Field | Type | Description |
| --- | --- | --- |
| `alertId` | string | Stable alert ID (WHO DON ID, e.g. `2026-DON622`) |
| `donId` | string | WHO Disease Outbreak News ID |
| `title` | string | Alert title |
| `summary` | string | WHO summary text (max 2000 chars) |
| `publishedAt` | date-time | Publication time |
| `updatedAt` | date-time | Last modified time |
| `diseases` | array | Diseases detected in the alert (e.g. `["Ebola"]`) |
| `url` | string | Canonical WHO alert page |
| `isNew` | boolean | True when the alert was not seen before |
| `source` | string | Always `who` |
| `retrievedAt` | date-time | Collection time |

`RUN_SUMMARY` contains `baseline`, `pagesFetched`, `fetchedAlerts`, `matchedAlerts`, `newAlerts`, `returnedAlerts`, filters, `stateSize` and the newest publication date.

### How to run

1. Optionally set `diseases`, `countries`, `regions` or `keywords`.
2. Keep `onlyNew: true` for alerting, or set it to `false` to always return the lookback window.
3. Run in Apify Console or through the API, or schedule it (e.g. hourly or daily).
4. Export the dataset as JSON, CSV or Excel, or connect an Apify integration/webhook for notifications.

### Limits

- The feed is read in pages of 50, up to 6 pages per run.
- Summaries are capped at 2000 characters.
- The state keeps the newest 2000 alert IDs; older IDs are ignored when they fall out of the lookback window.
- WHO sometimes revises or removes an alert. Records are keyed by DON ID, so a revision keeps the same ID and is not treated as a new alert.

### Responsible use

Use this Actor for public health monitoring with data published by WHO. Attribute WHO as the source and keep the canonical `url` with any redistribution. Do not present the output as medical advice.

# Actor input Schema

## `diseases` (type: `array`):

Only return alerts whose title or summary mentions one of these terms, e.g. Ebola, cholera, mpox, H5N1.

## `countries` (type: `array`):

Only return alerts that mention one of these countries or places, e.g. Democratic Republic of the Congo, Kenya.

## `regions` (type: `array`):

Only return alerts that mention one of these regions. Common aliases are resolved, e.g. Africa also matches African Region.

## `keywords` (type: `string`):

Free-text phrase that must appear in the alert title or summary.

## `lookbackDays` (type: `integer`):

How far back to read the feed. The first baseline run returns matching alerts inside this window.

## `maxResults` (type: `integer`):

Maximum number of alerts to return per run.

## `onlyNew` (type: `boolean`):

After the first baseline run, return only alerts that were not seen before.

## `includeSummary` (type: `boolean`):

Include the WHO summary text (capped at 2000 characters).

## `resetState` (type: `boolean`):

Clear the stored list of seen alerts and treat this run as a new baseline.

## Actor input object example

```json
{
  "diseases": [],
  "countries": [],
  "regions": [],
  "keywords": "",
  "lookbackDays": 30,
  "maxResults": 25,
  "onlyNew": true,
  "includeSummary": true,
  "resetState": false
}
```

# Actor output Schema

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

No description

## `runSummary` (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("scrapeai/outbreak-watch").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("scrapeai/outbreak-watch").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 scrapeai/outbreak-watch --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scrapeai/outbreak-watch"
        }
    }
}
```

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/67GGJwMe4qnpogrSX/builds/b8WDGxwvV417dDlXG/openapi.json
