# FDA Orange Book Scraper (`crawlerbros/fda-orange-book-scraper`) Actor

Scrape FDA's Orange Book - Approved Drug Products with Therapeutic Equivalence Evaluations. Search by drug name, active ingredient, applicant, or application number; browse by approval date; look up patents and marketing exclusivities. Sourced from FDA's official monthly bulk data files.

- **URL**: https://apify.com/crawlerbros/fda-orange-book-scraper.md
- **Developed by:** [Crawler Bros](https://apify.com/crawlerbros) (community)
- **Categories:** Automation, Developer tools, Integrations
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 results

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

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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 Orange Book Scraper

Scrape the FDA's **Orange Book** — "Approved Drug Products with Therapeutic Equivalence Evaluations" — the official register of every FDA-approved prescription and over-the-counter drug, along with the patents and marketing exclusivities that protect them. Search by drug name, active ingredient, applicant, or application number; browse approvals by date; or pull patent/exclusivity data directly. Sourced from FDA's official monthly bulk data files — no login, no API key, no cookies.

### What this actor does

- **Five modes:** `search`, `byApplicationNumbers`, `byApprovalDateRange`, `patentExclusivityLookup`, `findEquivalents`
- **Search axes:** drug/brand name, active ingredient, applicant (manufacturer), application number, dosage form, route of administration, strength — each independently filterable and combinable
- **Filters:** application type (NDA/ANDA), drug type (Rx/OTC/Discontinued), therapeutic equivalence (TE) code, Reference Listed Drug / Reference Standard flags, has-patents / has-exclusivity, approval date range
- **Sorting:** approval date (newest/oldest), ingredient/applicant/trade name (A-Z), patent/exclusivity expiration date (soonest/latest)
- **Generic/brand equivalence lookup:** `findEquivalents` finds every product sharing the same ingredient + dosage form + route + strength as a reference application number — the same logic pharmacists use to identify substitutable generics
- **Patents & exclusivities:** nested on every product record, or pulled standalone via `patentExclusivityLookup` (filterable by patent number, exclusivity code, expiration date)
- **Empty fields are omitted** — every field in the output is real FDA data

### Data source

FDA publishes the entire Orange Book every month as a single bulk download (tilde-delimited `products.txt`, `patent.txt`, `exclusivity.txt`) from the [Orange Book Data Files](https://www.fda.gov/drugs/drug-approvals-and-databases/orange-book-data-files) page. The actor downloads and parses this file directly — this is the same underlying data that powers the legacy `accessdata.fda.gov` search UI, but far more reliable to consume programmatically (no session-bound form posts, no CAPTCHA, no rate limiting).

### Output per record

**Products** (`recordType: "orangeBookProduct"`):
- `applicationNumber` (e.g. `NDA020610`, `ANDA018613`), `applicationType`, `applicationTypeFull`, `productNumber`
- `ingredient`, `dosageForm`, `route`, `tradeName`, `applicant`, `applicantFullName`, `strength`
- `teCodes[]`, `teCodeDescription` — therapeutic equivalence rating
- `approvalDate` (ISO), `approvalDateRaw` (original FDA text, including legacy "Approved Prior to Jan 1, 1982")
- `referenceListedDrug`, `referenceStandard` (booleans)
- `drugType` (`RX`/`OTC`/`DISCN`), `drugTypeFull`
- `patents[]` — nested: `patentNumber`, `expirationDate`, `drugSubstancePatent`, `drugProductPatent`, `patentUseCode`, `delisted`, `submissionDate`, `hasPediatricExtension`, `isReissuePatent`
- `exclusivities[]` — nested: `exclusivityCode`, `description`, `expirationDate`
- `patentCount`, `exclusivityCount`
- `sourceUrl` — direct link to the product's FDA Orange Book page
- `recordType`, `scrapedAt`

**Patents / exclusivities** (`patentExclusivityLookup` mode; `recordType: "orangeBookPatent"` / `"orangeBookExclusivity"`):
- Same patent/exclusivity fields as above, flattened, plus `applicationNumber`, `productNumber`, `ingredient`, `tradeName`, `applicant` (joined from the product), `sourceUrl`

**Generic/brand equivalents** (`findEquivalents` mode; `recordType: "orangeBookProduct"`):
- Same product fields as above, plus `isReferenceProduct` (`true` for the application number you searched, `false` for its equivalents)

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `mode` | select | `search` | `search` / `byApplicationNumbers` / `byApprovalDateRange` / `patentExclusivityLookup` / `findEquivalents` |
| `searchQuery` | string | `ibuprofen` | Free-text match across ingredient, trade name, applicant, application number (mode=search) |
| `activeIngredient` | string | – | Substring match on active ingredient |
| `tradeName` | string | – | Substring match on brand/trade name |
| `applicantName` | string | – | Substring match on applicant |
| `applicationNumberQuery` | string | – | Substring/suffix match on application number |
| `applicationNumbers` | array | `["NDA020699"]` | Exact application numbers (mode=byApplicationNumbers); exactly one reference number (mode=findEquivalents) |
| `applicationType` | select | Any | `NDA` / `ANDA` |
| `drugType` | select | Any | `RX` / `OTC` / `DISCN` |
| `teCode` | select | Any | Therapeutic equivalence code (AB, AB1-4, AA, AN, AO, AP, AP1-3, AT, AT1-3, BC, BD, BP, BS, BX) |
| `dosageFormQuery` | string | – | Substring match on dosage form (e.g. `TABLET`) |
| `routeQuery` | string | – | Substring match on route of administration (e.g. `ORAL`) |
| `strengthQuery` | string | – | Substring match on labeled strength (e.g. `200MG`) |
| `referenceListedDrugOnly` | boolean | `false` | Only RLD products |
| `referenceStandardOnly` | boolean | `false` | Only Reference Standard products |
| `hasPatentsOnly` | boolean | `false` | Only products with at least one listed patent |
| `hasExclusivityOnly` | boolean | `false` | Only products with at least one active exclusivity |
| `excludeReferenceProduct` | boolean | `false` | mode=findEquivalents: omit the reference product itself from results |
| `sortBy` | select | `default` | `approvalDateDesc` / `approvalDateAsc` / `ingredientAsc` / `applicantAsc` / `tradeNameAsc` / `expirationDateAsc` / `expirationDateDesc` |
| `approvalDateFrom` / `approvalDateTo` | string | – | ISO `YYYY-MM-DD`; required (either) for mode=byApprovalDateRange |
| `recordKind` | select | `both` | `patents` / `exclusivities` / `both` (mode=patentExclusivityLookup) |
| `patentNumberQuery` | string | – | Substring match on US patent number |
| `exclusivityCodeQuery` | string | – | Substring match on exclusivity code |
| `includeDelisted` | boolean | `true` | Include patents FDA flagged as delisted |
| `expirationDateFrom` / `expirationDateTo` | string | – | ISO `YYYY-MM-DD` patent/exclusivity expiration range |
| `maxItems` | integer | `100` | Hard cap (1–5000) |
| `proxyConfiguration` | proxy | `{useApifyProxy: true}` | Optional fallback if FDA ever blocks the direct connection |

#### Example: search by ingredient + drug type

```json
{
  "mode": "search",
  "activeIngredient": "metformin",
  "drugType": "RX",
  "applicationType": "ANDA",
  "maxItems": 50
}
````

#### Example: lookup by application number

```json
{
  "mode": "byApplicationNumbers",
  "applicationNumbers": ["NDA020610", "ANDA018613"]
}
```

#### Example: browse recent approvals

```json
{
  "mode": "byApprovalDateRange",
  "approvalDateFrom": "2024-01-01",
  "approvalDateTo": "2024-12-31",
  "maxItems": 100
}
```

#### Example: patents expiring soon for a given application

```json
{
  "mode": "patentExclusivityLookup",
  "applicationNumbers": ["NDA214070"],
  "recordKind": "patents",
  "sortBy": "expirationDateAsc"
}
```

#### Example: find generic equivalents of a brand-name drug

```json
{
  "mode": "findEquivalents",
  "applicationNumbers": ["NDA020402"],
  "excludeReferenceProduct": true
}
```

### Use cases

- **Generics/pharma competitive intelligence** — track patent and exclusivity expiration dates ahead of generic entry
- **Regulatory research** — verify therapeutic equivalence ratings before substitution
- **Legal/IP due diligence** — enumerate every patent covering a given NDA
- **Market access** — identify Rx-to-OTC switches and new approvals by date
- **Academic/health-policy research** — bulk export of approved-drug metadata

### FAQ

**What's the Orange Book?** FDA's official list of approved drug products with their therapeutic equivalence evaluations, patents, and exclusivities — the reference generics manufacturers use to identify bioequivalent substitutes and patent challenges.

**How fresh is the data?** FDA republishes the bulk data files monthly (typically the second week of each month, covering the prior month's changes). The actor always fetches the latest file at run time.

**Why not scrape accessdata.fda.gov directly?** That legacy ColdFusion search UI is session-bound and only supports one query at a time; the monthly bulk file contains the complete dataset and is far more reliable to consume at scale.

**What does `teCodeDescription` mean?** `A`-prefixed codes (`AB`, `AA`, `AT`, ...) indicate FDA considers the product therapeutically equivalent to the reference; `B`-prefixed codes (`BX`, `BC`, ...) indicate it is not (yet) rated equivalent.

**What if my application number isn't found?** `byApplicationNumbers` reports which numbers matched and which didn't via the run's status message — double check the type prefix (`NDA` vs `ANDA`) or try the bare digits.

**Are discontinued drugs included?** Yes — `drugType: "DISCN"` marks products FDA has moved to the discontinued section; filter with `drugType` to include/exclude them.

**How does `findEquivalents` decide what's a match?** It matches on identical ingredient + dosage form + route of administration + strength (FDA's own basis for bioequivalence grouping). It does not require the same TE code, so review `teCodes`/`teCodeDescription` on each result before treating a match as an approved substitute.

**Why are `dosageFormQuery` / `routeQuery` free-text instead of dropdowns?** FDA's Orange Book stores dosage form and route as combined, often multi-value strings (e.g. `TABLET, EXTENDED RELEASE` or `INTRAMUSCULAR, INTRAVENOUS, SUBCUTANEOUS`) — there are 117+ distinct dosage-form strings and 79+ route strings, most of which are combinations. A substring match lets you match the atomic term (`ORAL`) regardless of which combination it appears in.

# Actor input Schema

## `mode` (type: `string`):

What to fetch.

## `searchQuery` (type: `string`):

Free-text query matched against ingredient, trade name, applicant, and application number.

## `activeIngredient` (type: `string`):

Case-insensitive substring match against the active ingredient name(s). Combines with other filters.

## `tradeName` (type: `string`):

Case-insensitive substring match against the brand/trade name.

## `applicantName` (type: `string`):

Case-insensitive substring match against the applicant (manufacturer) name.

## `applicationNumberQuery` (type: `string`):

Substring/suffix match against the application number, e.g. `020610`, `NDA020610`.

## `applicationNumbers` (type: `array`):

Exact application numbers to look up, e.g. `NDA020610`, `ANDA018613`, or bare `020610`. mode=byApplicationNumbers accepts multiple; mode=findEquivalents uses exactly one as the reference product.

## `applicationType` (type: `string`):

Filter to NDA (brand/new drug) or ANDA (generic) applications only.

## `drugType` (type: `string`):

Filter to prescription, over-the-counter, or discontinued products.

## `teCode` (type: `string`):

Filter to products carrying this exact TE code.

## `referenceListedDrugOnly` (type: `boolean`):

Only emit products marked as the Reference Listed Drug for their group.

## `referenceStandardOnly` (type: `boolean`):

Only emit products marked as the Reference Standard for bioequivalence testing.

## `dosageFormQuery` (type: `string`):

Case-insensitive substring match against the dosage form (e.g. `TABLET`, `INJECTABLE`, `CREAM`). There are 117+ distinct dosage forms and many appear only combined with a route (e.g. `TABLET, EXTENDED RELEASE`), so this is a free-text contains-match rather than an exact dropdown.

## `routeQuery` (type: `string`):

Case-insensitive substring match against the route of administration (e.g. `ORAL`, `TOPICAL`, `INTRAVENOUS`). FDA lists 79+ route strings, many as multi-route combinations (e.g. `INTRAMUSCULAR, INTRAVENOUS`), so this is a contains-match rather than an exact dropdown.

## `strengthQuery` (type: `string`):

Case-insensitive substring match against the labeled strength (e.g. `200MG`, `10MG/ML`).

## `hasPatentsOnly` (type: `boolean`):

Only emit products that have at least one listed patent.

## `hasExclusivityOnly` (type: `boolean`):

Only emit products that have at least one active marketing exclusivity.

## `excludeReferenceProduct` (type: `boolean`):

When true, omit the reference product itself from the results — only its equivalents (other applicants' matching products) are emitted.

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

Sort order for emitted records. Approval-date and name sorts apply to product modes (search / byApplicationNumbers / byApprovalDateRange / findEquivalents); expiration-date sorts apply to mode=patentExclusivityLookup.

## `approvalDateFrom` (type: `string`):

ISO date `YYYY-MM-DD`. Drop products approved before this date. Required (with/without `approvalDateTo`) for mode=byApprovalDateRange; optional filter on other modes.

## `approvalDateTo` (type: `string`):

ISO date `YYYY-MM-DD`. Drop products approved after this date.

## `recordKind` (type: `string`):

Which entity type to emit.

## `patentNumberQuery` (type: `string`):

Substring match against the US patent number.

## `exclusivityCodeQuery` (type: `string`):

Substring match against the exclusivity code, e.g. `NCE`, `ODE`, `PED`.

## `includeDelisted` (type: `boolean`):

Whether to include patents FDA has flagged as delisted from the Orange Book (mode=patentExclusivityLookup).

## `expirationDateFrom` (type: `string`):

ISO date `YYYY-MM-DD`. Drop patents/exclusivities expiring before this date.

## `expirationDateTo` (type: `string`):

ISO date `YYYY-MM-DD`. Drop patents/exclusivities expiring after this date.

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

Hard cap on emitted records.

## `proxyConfiguration` (type: `object`):

Optional. FDA rarely blocks datacenter IPs; the actor tries a direct connection first and only engages this free Apify datacenter proxy as a fallback if the direct download is blocked.

## Actor input object example

```json
{
  "mode": "search",
  "searchQuery": "ibuprofen",
  "applicationNumbers": [
    "NDA020699"
  ],
  "applicationType": "",
  "drugType": "",
  "teCode": "",
  "referenceListedDrugOnly": false,
  "referenceStandardOnly": false,
  "hasPatentsOnly": false,
  "hasExclusivityOnly": false,
  "excludeReferenceProduct": false,
  "sortBy": "default",
  "recordKind": "both",
  "includeDelisted": true,
  "maxItems": 100,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `orangeBookRecords` (type: `string`):

Dataset containing all scraped Orange Book products, patents, and exclusivities.

# 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 = {
    "mode": "search",
    "searchQuery": "ibuprofen",
    "applicationNumbers": [
        "NDA020699"
    ],
    "applicationType": "",
    "drugType": "",
    "teCode": "",
    "referenceListedDrugOnly": false,
    "referenceStandardOnly": false,
    "hasPatentsOnly": false,
    "hasExclusivityOnly": false,
    "excludeReferenceProduct": false,
    "sortBy": "default",
    "recordKind": "both",
    "includeDelisted": true,
    "maxItems": 100,
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("crawlerbros/fda-orange-book-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 = {
    "mode": "search",
    "searchQuery": "ibuprofen",
    "applicationNumbers": ["NDA020699"],
    "applicationType": "",
    "drugType": "",
    "teCode": "",
    "referenceListedDrugOnly": False,
    "referenceStandardOnly": False,
    "hasPatentsOnly": False,
    "hasExclusivityOnly": False,
    "excludeReferenceProduct": False,
    "sortBy": "default",
    "recordKind": "both",
    "includeDelisted": True,
    "maxItems": 100,
    "proxyConfiguration": { "useApifyProxy": True },
}

# Run the Actor and wait for it to finish
run = client.actor("crawlerbros/fda-orange-book-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 '{
  "mode": "search",
  "searchQuery": "ibuprofen",
  "applicationNumbers": [
    "NDA020699"
  ],
  "applicationType": "",
  "drugType": "",
  "teCode": "",
  "referenceListedDrugOnly": false,
  "referenceStandardOnly": false,
  "hasPatentsOnly": false,
  "hasExclusivityOnly": false,
  "excludeReferenceProduct": false,
  "sortBy": "default",
  "recordKind": "both",
  "includeDelisted": true,
  "maxItems": 100,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call crawlerbros/fda-orange-book-scraper --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "FDA Orange Book Scraper",
        "description": "Scrape FDA's Orange Book - Approved Drug Products with Therapeutic Equivalence Evaluations. Search by drug name, active ingredient, applicant, or application number; browse by approval date; look up patents and marketing exclusivities. Sourced from FDA's official monthly bulk data files.",
        "version": "1.0",
        "x-build-id": "PXtebvdJN99mB7Lde"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/crawlerbros~fda-orange-book-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-crawlerbros-fda-orange-book-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/crawlerbros~fda-orange-book-scraper/runs": {
            "post": {
                "operationId": "runs-sync-crawlerbros-fda-orange-book-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/crawlerbros~fda-orange-book-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-crawlerbros-fda-orange-book-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "mode"
                ],
                "properties": {
                    "mode": {
                        "title": "Mode",
                        "enum": [
                            "search",
                            "byApplicationNumbers",
                            "byApprovalDateRange",
                            "patentExclusivityLookup",
                            "findEquivalents"
                        ],
                        "type": "string",
                        "description": "What to fetch.",
                        "default": "search"
                    },
                    "searchQuery": {
                        "title": "Search query (mode=search)",
                        "type": "string",
                        "description": "Free-text query matched against ingredient, trade name, applicant, and application number.",
                        "default": "ibuprofen"
                    },
                    "activeIngredient": {
                        "title": "Active ingredient contains",
                        "type": "string",
                        "description": "Case-insensitive substring match against the active ingredient name(s). Combines with other filters."
                    },
                    "tradeName": {
                        "title": "Trade name contains",
                        "type": "string",
                        "description": "Case-insensitive substring match against the brand/trade name."
                    },
                    "applicantName": {
                        "title": "Applicant contains",
                        "type": "string",
                        "description": "Case-insensitive substring match against the applicant (manufacturer) name."
                    },
                    "applicationNumberQuery": {
                        "title": "Application number contains",
                        "type": "string",
                        "description": "Substring/suffix match against the application number, e.g. `020610`, `NDA020610`."
                    },
                    "applicationNumbers": {
                        "title": "Application numbers (mode=byApplicationNumbers / findEquivalents)",
                        "type": "array",
                        "description": "Exact application numbers to look up, e.g. `NDA020610`, `ANDA018613`, or bare `020610`. mode=byApplicationNumbers accepts multiple; mode=findEquivalents uses exactly one as the reference product.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "applicationType": {
                        "title": "Application type",
                        "enum": [
                            "",
                            "NDA",
                            "ANDA"
                        ],
                        "type": "string",
                        "description": "Filter to NDA (brand/new drug) or ANDA (generic) applications only.",
                        "default": ""
                    },
                    "drugType": {
                        "title": "Drug type",
                        "enum": [
                            "",
                            "RX",
                            "OTC",
                            "DISCN"
                        ],
                        "type": "string",
                        "description": "Filter to prescription, over-the-counter, or discontinued products.",
                        "default": ""
                    },
                    "teCode": {
                        "title": "Therapeutic equivalence (TE) code",
                        "enum": [
                            "",
                            "AA",
                            "AB",
                            "AB1",
                            "AB2",
                            "AB3",
                            "AB4",
                            "AN",
                            "AO",
                            "AP",
                            "AP1",
                            "AP2",
                            "AP3",
                            "AT",
                            "AT1",
                            "AT2",
                            "AT3",
                            "BC",
                            "BD",
                            "BP",
                            "BS",
                            "BX"
                        ],
                        "type": "string",
                        "description": "Filter to products carrying this exact TE code.",
                        "default": ""
                    },
                    "referenceListedDrugOnly": {
                        "title": "Reference Listed Drug (RLD) only",
                        "type": "boolean",
                        "description": "Only emit products marked as the Reference Listed Drug for their group.",
                        "default": false
                    },
                    "referenceStandardOnly": {
                        "title": "Reference Standard (RS) only",
                        "type": "boolean",
                        "description": "Only emit products marked as the Reference Standard for bioequivalence testing.",
                        "default": false
                    },
                    "dosageFormQuery": {
                        "title": "Dosage form contains",
                        "type": "string",
                        "description": "Case-insensitive substring match against the dosage form (e.g. `TABLET`, `INJECTABLE`, `CREAM`). There are 117+ distinct dosage forms and many appear only combined with a route (e.g. `TABLET, EXTENDED RELEASE`), so this is a free-text contains-match rather than an exact dropdown."
                    },
                    "routeQuery": {
                        "title": "Route of administration contains",
                        "type": "string",
                        "description": "Case-insensitive substring match against the route of administration (e.g. `ORAL`, `TOPICAL`, `INTRAVENOUS`). FDA lists 79+ route strings, many as multi-route combinations (e.g. `INTRAMUSCULAR, INTRAVENOUS`), so this is a contains-match rather than an exact dropdown."
                    },
                    "strengthQuery": {
                        "title": "Strength contains",
                        "type": "string",
                        "description": "Case-insensitive substring match against the labeled strength (e.g. `200MG`, `10MG/ML`)."
                    },
                    "hasPatentsOnly": {
                        "title": "Only products with patents",
                        "type": "boolean",
                        "description": "Only emit products that have at least one listed patent.",
                        "default": false
                    },
                    "hasExclusivityOnly": {
                        "title": "Only products with exclusivity",
                        "type": "boolean",
                        "description": "Only emit products that have at least one active marketing exclusivity.",
                        "default": false
                    },
                    "excludeReferenceProduct": {
                        "title": "Exclude reference product (mode=findEquivalents)",
                        "type": "boolean",
                        "description": "When true, omit the reference product itself from the results — only its equivalents (other applicants' matching products) are emitted.",
                        "default": false
                    },
                    "sortBy": {
                        "title": "Sort results by",
                        "enum": [
                            "default",
                            "approvalDateDesc",
                            "approvalDateAsc",
                            "ingredientAsc",
                            "applicantAsc",
                            "tradeNameAsc",
                            "expirationDateAsc",
                            "expirationDateDesc"
                        ],
                        "type": "string",
                        "description": "Sort order for emitted records. Approval-date and name sorts apply to product modes (search / byApplicationNumbers / byApprovalDateRange / findEquivalents); expiration-date sorts apply to mode=patentExclusivityLookup.",
                        "default": "default"
                    },
                    "approvalDateFrom": {
                        "title": "Approval date from (mode=byApprovalDateRange)",
                        "type": "string",
                        "description": "ISO date `YYYY-MM-DD`. Drop products approved before this date. Required (with/without `approvalDateTo`) for mode=byApprovalDateRange; optional filter on other modes."
                    },
                    "approvalDateTo": {
                        "title": "Approval date to (mode=byApprovalDateRange)",
                        "type": "string",
                        "description": "ISO date `YYYY-MM-DD`. Drop products approved after this date."
                    },
                    "recordKind": {
                        "title": "Record kind (mode=patentExclusivityLookup)",
                        "enum": [
                            "both",
                            "patents",
                            "exclusivities"
                        ],
                        "type": "string",
                        "description": "Which entity type to emit.",
                        "default": "both"
                    },
                    "patentNumberQuery": {
                        "title": "Patent number contains (mode=patentExclusivityLookup)",
                        "type": "string",
                        "description": "Substring match against the US patent number."
                    },
                    "exclusivityCodeQuery": {
                        "title": "Exclusivity code contains (mode=patentExclusivityLookup)",
                        "type": "string",
                        "description": "Substring match against the exclusivity code, e.g. `NCE`, `ODE`, `PED`."
                    },
                    "includeDelisted": {
                        "title": "Include delisted patents",
                        "type": "boolean",
                        "description": "Whether to include patents FDA has flagged as delisted from the Orange Book (mode=patentExclusivityLookup).",
                        "default": true
                    },
                    "expirationDateFrom": {
                        "title": "Expiration date from (mode=patentExclusivityLookup)",
                        "type": "string",
                        "description": "ISO date `YYYY-MM-DD`. Drop patents/exclusivities expiring before this date."
                    },
                    "expirationDateTo": {
                        "title": "Expiration date to (mode=patentExclusivityLookup)",
                        "type": "string",
                        "description": "ISO date `YYYY-MM-DD`. Drop patents/exclusivities expiring after this date."
                    },
                    "maxItems": {
                        "title": "Max items",
                        "minimum": 1,
                        "maximum": 5000,
                        "type": "integer",
                        "description": "Hard cap on emitted records.",
                        "default": 100
                    },
                    "proxyConfiguration": {
                        "title": "Proxy configuration",
                        "type": "object",
                        "description": "Optional. FDA rarely blocks datacenter IPs; the actor tries a direct connection first and only engages this free Apify datacenter proxy as a fallback if the direct download is blocked.",
                        "default": {
                            "useApifyProxy": true
                        }
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
