# FDA Recall Scraper - Drug, Device & Food Enforcement (`flash_scraper/fda-recall-scraper`) Actor

Scrape FDA drug, device & food recalls from the official openFDA API. Get clean, structured rows: recall number, severity (Class I/II/III), status, recalling firm, brand, reason & dates. Filter by type, severity, status, state & date; monitor new recalls; export CSV, JSON or Excel. No API key.

- **URL**: https://apify.com/flash\_scraper/fda-recall-scraper.md
- **Developed by:** [Flash Scrape](https://apify.com/flash_scraper) (community)
- **Categories:** News, Automation, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $5.00 / 1,000 results

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — 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

## FDA Recall Scraper - Drug, Device & Food Enforcement

**This FDA recall scraper turns the official openFDA enforcement data into a clean, queryable feed** — one flat row per recall with the recall number, product type, classification + plain-English **severity** (Class I/II/III → High/Medium/Low), status, recalling firm, brand / generic / manufacturer, reason for recall, distribution, ISO dates, and location. Pull **drug, medical-device, and food recalls** in one run, filter by severity / status / state / date / keyword, and export to CSV, JSON, or Excel.

Built for **pharma & medtech regulatory and quality teams, consultancies, biotech investors, and journalists** who need a structured recall feed for monitoring — not openFDA's raw, deeply-nested JSON. Official US government data, **no API key, no anti-bot.**

***

### Why use this instead of openFDA directly

openFDA is powerful but raw: verbose records, nested `openfda` objects, `YYYYMMDD` date strings, and three separate endpoints. This actor does the cleanup for you:

- **One clean flat row per recall** — drops straight into a spreadsheet or BI tool.
- **Explainable 0-100 `risk_score`** — not just a class letter. Every score ships with a `score_breakdown` (severity, recency, distribution scale, status, harm signals) **and** a plain-English `score_rationale`, so you can sort by real risk and see *why*. **No other recall scraper shows its work.**
- **Recall lifecycle** — `is_open`, `days_open`, and `time_to_classification_days` tell you what's still active and how fast the FDA moved.
- **Plain-English severity** — Class I/II/III mapped to High/Medium/Low + a `severity_rank` for sorting.
- **Brand / generic / manufacturer / NDC / UPC** lifted out of the nested `openfda` block.
- **ISO dates** (`YYYY-MM-DD`) instead of `YYYYMMDD`.
- **Drug + device + food merged** into one deduped dataset; sort by **date** or **risk score**.
- **Filters** for product type, severity, status, state, keyword, date range, **open-only**, and **minimum risk score**.
- Re-run on a schedule to **monitor new recalls** for a firm, brand, or category.

***

### How to use it

1. Pick **product types** (drugs / devices / food).
2. Optionally filter: **severity** (Class I = most serious), **status** (Ongoing / Completed / Terminated), **state**, a **search term** (firm, product, or contaminant), and a **date range**.
3. Run → get a clean, deduped, newest-first recall table.

#### Input

| Field | Type | Description |
|---|---|---|
| `productTypes` | array | `drug`, `device`, `food` (any combination). |
| `searchTerm` | string | Free text across firm, product, and reason. |
| `classification` | array | `Class I` / `Class II` / `Class III` severity filter. |
| `status` | string | Ongoing / Completed / Terminated. |
| `state` | string | Recalling-firm US state code (e.g. `CA`). |
| `dateFrom` / `dateTo` | string | Recall-initiation date range (`YYYY-MM-DD`). |
| `openOnly` | boolean | Keep only open / not-yet-terminated recalls (active risk). |
| `minScore` | integer | Keep only recalls with `risk_score` ≥ this (0-100). |
| `sortBy` | string | `date` (newest first) or `risk` (highest score first). |
| `maxItems` | integer | Max recalls (split across types). Default `200`. |
| `apiKey` | string | Optional free openFDA key for large runs. |

**Example input:**

```json
{
  "productTypes": ["drug", "device"],
  "classification": ["Class I"],
  "status": "Ongoing",
  "dateFrom": "2025-01-01",
  "maxItems": 500
}
```

#### JSON output sample

```json
{
  "recall_number": "D-1234-2025",
  "product_type": "drug",
  "classification": "Class I",
  "severity": "High",
  "severity_rank": 1,
  "risk_score": 88,
  "score_breakdown": { "severity": 40, "recency": 20, "status": 15, "distribution": 15, "harm": 10 },
  "score_rationale": "Class I (most serious — reasonable probability of serious harm/death); recall still ongoing (active risk); initiated 41 days ago; wide/nationwide distribution; harm signals: contaminat",
  "status": "Ongoing",
  "is_open": true,
  "days_open": 41,
  "time_to_classification_days": 15,
  "recalling_firm": "Acme Pharmaceuticals, Inc.",
  "brand_name": "ACME XR 20MG",
  "generic_name": "amphetamine mixed salts",
  "manufacturer": "Acme Pharmaceuticals USA, Inc.",
  "product_ndc": "12345-678-90",
  "upc": null,
  "product_description": "ACME XR 20 mg extended-release capsules, 100-count bottle",
  "reason_for_recall": "Failed dissolution specifications; possible contamination",
  "distribution_pattern": "Nationwide (US)",
  "initiation_date": "2025-03-18",
  "report_date": "2025-04-02",
  "termination_date": null,
  "firm_city": "Trenton",
  "firm_state": "NJ",
  "country": "United States",
  "event_id": "90123"
}
```

Results render as a clean, sortable table on the Output tab and export to CSV, JSON, or Excel.

#### Example output

A real sample from a live run:

| recall\_number | product\_type | classification | recalling\_firm | status | risk\_score |
|---|---|---|---|---|---|
| F-1671-2024 | food | Class I | Palmer & Company | Terminated | 70 |
| F-1170-2024 | food | Class I | HandNatural | Ongoing | 58 |
| F-1354-2023 | food | Class II | Cassanos Inc | Terminated | 40 |
| F-1472-2022 | food | Class II | Queen Bee Gardens, LLC | Terminated | 52 |

***

### Use cases

- **Recall monitoring** — schedule the actor to watch for new Class I recalls in your category or for a specific firm/brand.
- **Competitive & supplier risk** — track recalls hitting competitors or your suppliers/contract manufacturers.
- **Regulatory & quality intelligence** — feed a compliance dashboard with structured enforcement data.
- **Investment signals** — biotech/medtech catalyst tracking (a Class I recall moves markets).
- **Journalism & research** — query decades of recalls by firm, product, or reason.

***

### Use with AI agents & automation

Run from the Apify **MCP** server so AI agents (Claude, ChatGPT, Cursor) can query recalls as a tool call, schedule runs via **Make**, **n8n**, or **Zapier** to alert Slack/email on new Class I recalls, or sync the dataset to **Google Sheets** for a live recall dashboard. Clean flat JSON drops into compliance pipelines with no glue code.

***

### Pricing

**Pay-per-event — you're charged per recall record delivered.** Source data is the free public openFDA API, so there are no proxy or third-party costs. See the Apify Store page for the current per-result price.

***

### FAQ

**Where does the data come from?** The official **openFDA** API (api.fda.gov), maintained by the U.S. Food & Drug Administration — public government data.

**Do I need an API key?** No. It works key-free. Add a free openFDA key only for very large/high-frequency runs (higher rate limit).

**What do the classifications mean?** **Class I** = reasonable probability of serious harm or death; **Class II** = temporary/medically reversible harm; **Class III** = unlikely to cause harm. This actor maps them to High/Medium/Low.

**How far back does it go?** openFDA enforcement data spans well over a decade; use the date filters to scope it.

**Can I monitor new recalls?** Yes — schedule the actor with a `dateFrom` of the last few days (or a firm/brand `searchTerm`) and pipe results to Slack/email via Make/Zapier.

**Can I export to CSV or Google Sheets?** Yes — CSV, JSON, or Excel from the Output tab, or sync to Google Sheets via Make, n8n, or Zapier.

***

### Other Flash Scrape scrapers

- [Trustpilot Reviews Scraper](https://apify.com/flash_scraper/trustpilot-reviews-scraper) — company reviews & reputation
- [Amazon Product Scraper](https://apify.com/flash_scraper/amazon-product-scraper) — products, prices & ratings
- [Google Maps Leads Scraper](https://apify.com/flash_scraper/google-maps-leads-opener) — local business leads
- [Indeed Jobs Scraper](https://apify.com/flash_scraper/indeed-jobs-scraper) — job listings
- [Google Search Results Scraper](https://apify.com/flash_scraper/google-serp-scraper) — SERP & rankings

# Actor input Schema

## `productTypes` (type: `array`):

Which FDA enforcement datasets to pull.

## `searchTerm` (type: `string`):

Free-text match across recalling firm, product description, and reason for recall (e.g. a company name, drug, or contaminant). Leave empty for all.

## `classification` (type: `array`):

Class I = most serious (risk of death), Class II = moderate, Class III = minor. Leave empty for all.

## `status` (type: `string`):

Filter by recall status: 'Ongoing' (still active), 'Completed', or 'Terminated' (closed by FDA). Leave empty ('Any') for all.

## `state` (type: `string`):

US state code of the recalling firm (e.g. 'CA', 'NY'). Leave empty for all.

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

Only recalls initiated on/after this date (YYYY-MM-DD). Optional.

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

Only recalls initiated on/before this date (YYYY-MM-DD). Optional.

## `openOnly` (type: `boolean`):

Return only recalls that are still open / ongoing (no termination date) — the active-risk subset.

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

Only return recalls with a computed risk score (0-100) at or above this. 0 = no filter.

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

Order results by recall date (newest first) or by computed risk score (highest first).

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

Maximum number of recall records to return (split across the selected product types).

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

A free openFDA API key (open.fda.gov/apis/authentication) lifts the rate limit for large runs. Not required for normal use.

## Actor input object example

```json
{
  "productTypes": [
    "drug",
    "device",
    "food"
  ],
  "classification": [],
  "status": "",
  "openOnly": false,
  "minScore": 0,
  "sortBy": "date",
  "maxItems": 200
}
```

# Actor output Schema

## `results` (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("flash_scraper/fda-recall-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("flash_scraper/fda-recall-scraper").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 '{}' |
apify call flash_scraper/fda-recall-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

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