# FDA Intelligence — Approvals, Recalls & Adverse Events (AI) (`noniner/fda-intelligence`) Actor

Search FDA data via openFDA: drug approvals, recalls/enforcement and adverse-event signals for any drug or company — with an AI summary of the regulatory and safety picture. For pharma, health, regulatory and investors.

- **URL**: https://apify.com/noniner/fda-intelligence.md
- **Developed by:** [Fredrik Hansson](https://apify.com/noniner) (community)
- **Categories:** AI, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$150.00 / 1,000 query analyzeds

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

## FDA Intelligence — Approvals, Recalls & Adverse Events (AI)

**Type a drug or a company. Get its FDA regulatory and safety picture in one pass.** This Actor searches the official [openFDA](https://open.fda.gov/) drug API for any brand name, generic name or manufacturer — pulling **recalls/enforcement actions**, a representative **drug label** (approval and usage info), and **adverse-event signals** — then uses OpenAI to write a grounded **regulatory + safety summary** with a single **safety signal** you can scan at a glance.

You bring the names. It hands back the paper trail plus a plain-English read on it.

> **This is not medical advice.** Adverse-event reports are **not proof of causation** — a report means someone filed it, not that the drug caused the effect. Treat every signal here as a lead to investigate, not a conclusion.

***

### The flow

```
  "Ozempic", "Pfizer",        openFDA drug API            recalls + labels + adverse        AI summary
   "semaglutide", ...    →    (enforcement/label/   →     events, aggregated per      →     safety signal +
                               event endpoints)            query                             regulatory read
```

1. **Give drug or company names** in `queries` — brand names (`Ozempic`, `Tylenol`), generics (`semaglutide`, `acetaminophen`) or firms (`Pfizer`).
2. **The Actor queries openFDA** across the datasets you pick: recalls (enforcement), drug labels, and adverse events (FAERS). openFDA is the FDA's own public API — free, no key required.
3. **Everything is aggregated per query** — recall count, worst recall classification, adverse-event total, top reported reactions, manufacturers.
4. **OpenAI summarizes** the gathered data into a safety signal and a short regulatory read — grounded only in what openFDA returned.

***

### What you get per query

For every drug or company, the Actor produces:

1. **Recall records** — one per recall found: `recallingFirm`, `reasonForRecall`, `classification` (Class I / II / III), `status`, `recallInitiationDate`, `productDescription`.
2. **A representative drug label** — `indicationsAndUsage`, `warnings`, `manufacturerName`, `effectiveTime`, `route` (approval and usage info pulled from the FDA label).
3. **An adverse-event signal** — the total number of adverse-event reports (from `meta.results.total`) and a sample of the most-reported reactions.
4. **A per-query summary record** with the headline numbers plus the **AI layer** (OpenAI `gpt-4o-mini`):
   - **`safetySignal`** — `low` · `moderate` · `elevated` · `unclear`, reflecting the severity/volume of recalls and adverse-event reports in the data.
   - **`regulatorySummary`** — 2–3 sentences on the regulatory and safety picture.
   - **`keyRecalls`** — the most serious recalls (reason, classification, date).
   - **`commonAdverseReactions`** — the reactions seen most in the reports.
   - **`approvalInfo`** — one sentence drawn from the label, if present.
   - **`caveat`** — a required disclaimer that adverse-event reports are not proof of causation and this is not medical advice.

Every field is grounded **only** in the openFDA data — nothing is invented. When a dataset returns nothing (openFDA's "No matches found"), that part is simply empty and the summary is built from what's available.

***

### Three ways people use it

- **Pharma & drug-safety monitoring (pharmacovigilance)** — track **drug recalls**, enforcement classifications and **adverse events** for your own products or your competitors', with the **openFDA API** data aggregated and a safety read on top. Watch a portfolio of brand and generic names in one run.
- **Regulatory due diligence** — for a deal, a supplier or a formulary decision, pull **FDA approvals**, label warnings and the recall history for a drug or a manufacturer in seconds, with the source records attached.
- **Health & investor research** — size up a drug or a pharma company fast: is there a pattern of Class I recalls? A spike in adverse-event reports? A clean label? The summary and safety signal make a long list of names triageable.

Keywords: openFDA API, drug recalls, adverse events, FDA approvals, pharmacovigilance, drug safety, enforcement reports, FAERS, drug labels.

***

### Input

| Field | Type | Notes |
|---|---|---|
| `queries` | array | **Required.** Drug brand/generic names or companies, one per line (`Ozempic`, `Pfizer`, `semaglutide`). |
| `datasets` | array | Which openFDA endpoints to pull: `enforcement` (recalls), `label` (approval/usage info), `event` (adverse events). Default all three. |
| `maxPerDataset` | integer | Records to pull per dataset per query. Default `10`. |
| `maxResults` | integer | Cap how many queries to analyze. Default `100`. |
| `maxConcurrency` | integer | Queries in parallel. Default `2` (openFDA rate-limits). |
| `model` | string | OpenAI model override. Default `gpt-4o-mini`. |

#### Minimal input example

```json
{
  "queries": ["Ozempic", "Tylenol"],
  "datasets": ["enforcement", "label", "event"],
  "maxPerDataset": 10
}
```

***

### Output example

A per-query **summary** record:

```json
{
  "query": "Tylenol",
  "recordType": "summary",
  "recallCount": 3,
  "adverseEventTotal": 48213,
  "worstClassification": "Class II",
  "topReactions": ["Drug ineffective", "Nausea", "Hepatic failure", "Overdose"],
  "manufacturers": ["Johnson & Johnson", "McNeil Consumer Healthcare"],
  "safetySignal": "moderate",
  "keyRecalls": [
    { "reason": "Musty/moldy odor from trace chemical", "classification": "Class II", "date": "2010-06-18" }
  ],
  "commonAdverseReactions": ["Hepatic failure", "Overdose", "Nausea"],
  "approvalInfo": "Acetaminophen is labeled for the temporary relief of minor aches, pains and fever.",
  "regulatorySummary": "Tylenol (acetaminophen) is a long-marketed OTC analgesic with a well-characterised label. The recall history is limited to lower-severity Class II actions, while adverse-event reports are high in absolute terms, as expected for a very widely used drug.",
  "caveat": "Adverse-event reports do not prove the drug caused the effect, and this is not medical advice."
}
```

Plus one `recall` record per recall, one `label` record, and one `adverse-summary` record per query.

***

### Pay-per-event pricing

This Actor uses **pay-per-event** billing with a single event:

| Event | Charged when | Price |
|---|---|---|
| `query-analyzed` | Once per drug or company searched across openFDA (recalls, labels, adverse events) and summarized with AI. | **$0.15** |

The Actor logs its OpenAI token usage and the estimated AI cost at the end of every run, so the event price stays safely above the model cost.

***

### Data source

All regulatory data comes from the **official [openFDA](https://open.fda.gov/) drug API** — the FDA's own public, free interface to enforcement (recall), drug label and adverse-event (FAERS) data. No API key is required. An optional `OPENFDA_API_KEY` environment variable raises openFDA's rate limits; without it the Actor paces its requests to stay within the public limits (~240 requests/minute, 1000/day).

**openFDA's own caveat applies:** adverse-event reports are submitted by consumers, clinicians and manufacturers and are **not verified** — they do not establish that a drug caused a reaction, and the data should not be used alone to draw conclusions about safety.

***

### Setup

The AI summary calls the OpenAI API. Set the environment variable / secret **`OPENAI_API_KEY`** on the Actor. Optionally set **`OPENFDA_API_KEY`** for higher openFDA rate limits.

***

### Use it from an AI agent (Apify MCP server)

This Actor is available through the [Apify MCP server](https://mcp.apify.com), so AI agents (Claude, ChatGPT, or anything that speaks MCP) can call it as a tool — hand it a list of drug or company names and read back the recalls, labels, adverse-event signals and AI summary — with no custom integration code.

***

### Run it locally

```bash
npm install
## put your input in storage/key_value_stores/default/INPUT.json
export OPENAI_API_KEY=sk-...
apify run -p
```

***

### Related actors

- [ClinicalTrials Intelligence](https://apify.com/noniner/clinicaltrials-intelligence) — Search and summarize clinical trials for any drug, condition or sponsor.
- [Research Paper Intelligence](https://apify.com/noniner/research-paper-intelligence) — Find and summarize scientific papers for any topic or author.
- [SEC Filings Extractor](https://apify.com/noniner/sec-filings-extractor) — Pull and structure data from SEC filings for any public company.
- [Google News Scraper](https://apify.com/noniner/google-news-scraper) — Track news coverage for any company, brand or topic.

***

**Part of the [No Niner](https://noniner.io) toolkit** — no-code web scraping, enrichment & AI data tools, all pay-per-use. Browse the full set at **[noniner.io](https://noniner.io)**.

# Actor input Schema

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

Drug brand/generic names or companies (e.g. "Ozempic", "Pfizer", "semaglutide"). One per line.

## `datasets` (type: `array`):

Which openFDA drug endpoints to pull: "enforcement" = recalls, "label" = drug labels/approval info, "event" = adverse events.

## `maxPerDataset` (type: `integer`):

How many records to pull per dataset, per query.

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

Max drugs/companies to analyze. One pay-per-event charge per query analyzed.

## `maxConcurrency` (type: `integer`):

Queries processed in parallel. Kept low because openFDA rate-limits.

## `model` (type: `string`):

Override the model (default gpt-4o-mini).

## Actor input object example

```json
{
  "queries": [
    "Ozempic",
    "Tylenol"
  ],
  "datasets": [
    "enforcement",
    "label",
    "event"
  ],
  "maxPerDataset": 10,
  "maxResults": 100,
  "maxConcurrency": 2
}
```

# Actor output Schema

## `findings` (type: `string`):

All recalls, labels, adverse-event summaries and per-query summaries in the default dataset.

# 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": [
        "Ozempic",
        "Tylenol"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("noniner/fda-intelligence").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": [
        "Ozempic",
        "Tylenol",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("noniner/fda-intelligence").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 '{
  "queries": [
    "Ozempic",
    "Tylenol"
  ]
}' |
apify call noniner/fda-intelligence --silent --output-dataset

```

## MCP server setup

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

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/hTM7UXVMlk55L5Duy/builds/Qb5l3Xhnj3hvWfyPp/openapi.json
