OpenFDA Drug Product Label¶
Queries the OpenFDA Drug Label endpoint to retrieve labeled drug information (e.g., warnings, adverse reactions, interactions). You can search or count results by specific label fields, optionally enforcing exact matches and limiting the number of returned items. Returns two JSON-formatted strings: one for results and one for API metadata.

Usage¶
Use this node when you need structured information from FDA drug product labels for downstream analytics, summarization, or compliance checks. Typical workflow: choose a label field (e.g., warnings), provide a value to look for (e.g., a substance or keyword), select whether to search or count, optionally enforce exact matches, and set a limit. Feed the results JSON into parsing or reporting nodes, and use the metadata JSON for paging or auditing.
Inputs¶
| Field | Required | Type | Description | Example |
|---|---|---|---|---|
| field_value | True | STRING | The value to search for within the selected label field. Used as the query term. | aspirin |
| field | True | One of: abuse, adverse reactions, components, drug interactions, effective time, general_precautions, instructions for use, nursing_mothers, overdosage, precautions, warnings | The drug label field to query against. | warnings |
| action | True | ENUM [search, count] | Choose 'search' to retrieve matching records or 'count' to get aggregated counts by the selected field. | search |
| exact_match | True | BOOLEAN | If true, the search is performed as an exact match for the selected field. | false |
| limit | True | INT | Maximum number of results (or count buckets) to return. Minimum is 1. | 3 |
Outputs¶
| Field | Type | Description | Example |
|---|---|---|---|
| results | STRING | JSON-formatted string of the OpenFDA API 'results' payload matching the query. | [{ "id": " |
| metadata | STRING | JSON-formatted string of the OpenFDA API 'meta' object (e.g., information about request, results, and pagination). | { "disclaimer": "...", "results": { "skip": 0, "limit": 3, "total": 123 } } |
Important Notes¶
- Supported fields: abuse, adverse reactions, components, drug interactions, effective time, general_precautions, instructions for use, nursing_mothers, overdosage, precautions, warnings.
- Exact match behavior: When enabled, the query uses an exact match variant of the selected field.
- Limit: Must be at least 1; use higher values responsibly to avoid large payloads.
- Output format: Both outputs are strings containing JSON. Downstream nodes expecting structured data may need to parse the JSON first.
- External service: This node relies on the public OpenFDA API. Availability, latency, and rate limits are governed by that service.
Troubleshooting¶
- Empty or unexpected results: Verify the 'field' matches the intended label content and adjust 'field_value' or disable 'exact_match' if too restrictive.
- Rate limiting or service errors: If you encounter API errors or timeouts, reduce 'limit', try again later, or refine the query to return fewer results.
- JSON handling issues downstream: Remember outputs are JSON strings; ensure your next step parses the JSON before field-level access.
- 'count' action returns unexpected structure: The API may format count results differently from search results. Inspect the 'results' JSON to confirm the structure and adjust parsing logic accordingly.