Skip to main content
Glama

Openfda Drug Profile

openfda_drug_profile
Read-only

Resolve one drug name to its FDA identity, then fan out in parallel across the bounded per-drug openFDA endpoints and merge into one profile: identity, label highlights, adverse-event summary, recall history, Drugs@FDA approval, and shortage status. Replaces chaining openfda_get_drug_label, openfda_search_adverse_events, openfda_search_recalls, openfda_search_drug_approvals, and openfda_search_drug_shortages — and reconciles the identifier drift between endpoints that makes that chaining error-prone. Each section is best-effort: a miss returns null rather than failing the call. For deep dives into any one area, use the dedicated tool.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
drugYesDrug name to profile — brand or generic (e.g. "metformin", "Humira", "Glucophage"). Resolved once to canonical FDA identifiers, which then key every sub-query.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
metaNoRequest metadata.
errorNoPresent when the call failed. Absent on success.
labelNoLabel highlights from drug/label, or null when no label matched.
noticeNoGuidance when the drug could not be resolved or upstream errors degraded the profile. Absent on a fully populated profile.
recallsNoRecent drug/enforcement recall actions (may be empty).
approvalNoDrugs@FDA approval summary, or null when no application matched.
degradedNoSub-queries that failed upstream, empty when every section resolved. A section listed here is unknown, not absent — a null section with no entry here genuinely has no FDA record.
identityNoIdentity resolved once and reused across every sub-query to avoid identifier drift.
shortageNoCurrent or most-recent drug shortage status, or null when none on record.
sectionsFoundNoHow many profile sections (label, adverse_events, recalls, approval, shortage) returned data.
adverse_eventsNoAdverse-event summary aggregated over drug/event, or null when unavailable.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed19 schema fields changed
    • changedOutput schema / properties / approval / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "applicationNumber": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "NDA/ANDA application number."
      -      },
      -      "marketingStatus": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Derived marketing/approval status."
      -      },
      -      "sponsor": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Sponsor/applicant name."
      -      }
      -    },
      -    "required": [
      -      "applicationNumber",
      -      "sponsor",
      -      "marketingStatus"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "applicationNumber": {
      +        "description": "NDA/ANDA application number.",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "marketingStatus": {
      +        "description": "Derived marketing/approval status.",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "sponsor": {
      +        "description": "Sponsor/applicant name.",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      }
      +    },
      +    "required": [
      +      "applicationNumber",
      +      "sponsor",
      +      "marketingStatus"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • removedOutput schema / properties / identity / properties / generic_name / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / identity / properties / generic_name / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / identity / properties / product_ndc / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / identity / properties / product_ndc / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / identity / properties / rxcui / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / identity / properties / rxcui / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / identity / properties / spl_set_id / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / identity / properties / spl_set_id / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • changedOutput schema / properties / label / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "dosage": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Dosage and administration (truncated)."
      -      },
      -      "indications": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Indications and usage (truncated)."
      -      },
      -      "warnings": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Warnings (truncated) — boxed warning or warnings_and_cautions for Rx labels, falling back to the OTC-monograph warnings section."
      -      }
      -    },
      -    "required": [
      -      "indications",
      -      "warnings",
      -      "dosage"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "dosage": {
      +        "description": "Dosage and administration (truncated).",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "indications": {
      +        "description": "Indications and usage (truncated).",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "warnings": {
      +        "description": "Warnings (truncated) — boxed warning or warnings_and_cautions for Rx labels, falling back to the OTC-monograph warnings section.",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      }
      +    },
      +    "required": [
      +      "indications",
      +      "warnings",
      +      "dosage"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • removedOutput schema / properties / recalls / items / properties / classification / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / recalls / items / properties / classification / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / recalls / items / properties / date / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / recalls / items / properties / date / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / recalls / items / properties / reason / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / recalls / items / properties / reason / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / recalls / items / properties / recalling_firm / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / recalls / items / properties / recalling_firm / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • changedOutput schema / properties / shortage / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "availability": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Availability note (truncated)."
      -      },
      -      "status": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Shortage status (Current/Resolved)."
      -      }
      -    },
      -    "required": [
      -      "status",
      -      "availability"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "availability": {
      +        "description": "Availability note (truncated).",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "status": {
      +        "description": "Shortage status (Current/Resolved).",
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      }
      +    },
      +    "required": [
      +      "status",
      +      "availability"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
  2. Changed6 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedInput schema / additionalProperties
      Added value: +false
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedOutput schema / anyOf
      Added value: +[
      +  {
      +    "not": {
      +      "required": [
      +        "error"
      +      ]
      +    },
      +    "required": [
      +      "meta",
      +      "identity",
      +      "label",
      +      "adverse_events",
      +      "recalls",
      +      "approval",
      +      "shortage",
      +      "degraded",
      +      "sectionsFound"
      +    ]
      +  },
      +  {
      +    "required": [
      +      "error"
      +    ]
      +  }
      +]
    • addedOutput schema / properties / error
      Added value: +{
      +  "additionalProperties": {},
      +  "description": "Present when the call failed. Absent on success.",
      +  "properties": {
      +    "code": {
      +      "description": "JSON-RPC error code for this failure.",
      +      "maximum": 9007199254740991,
      +      "minimum": -9007199254740991,
      +      "type": "integer"
      +    },
      +    "data": {
      +      "additionalProperties": {},
      +      "properties": {
      +        "reason": {
      +          "description": "Machine-readable failure mode. Declared by this tool: `blank_drug_name`: The drug name carries no searchable character — only quotes, backslashes, or whitespace. Other values are possible when a failure originates below the handler.",
      +          "examples": [
      +            "blank_drug_name"
      +          ],
      +          "type": "string"
      +        },
      +        "recovery": {
      +          "additionalProperties": {},
      +          "description": "Actionable next step for the caller.",
      +          "properties": {
      +            "hint": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "hint"
      +          ],
      +          "type": "object"
      +        },
      +        "retryable": {
      +          "description": "Whether retrying may succeed.",
      +          "type": "boolean"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "message": {
      +      "description": "Human-readable description of what went wrong.",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "code",
      +    "message"
      +  ],
      +  "type": "object"
      +}
    • removedOutput schema / required
      Removed value: -[
      -  "meta",
      -  "identity",
      -  "label",
      -  "adverse_events",
      -  "recalls",
      -  "approval",
      -  "shortage",
      -  "degraded",
      -  "sectionsFound"
      -]
  3. Changed3 schema fields changed
    • addedInput schema / properties / drug / pattern
      Added value: +"\\S"
    • addedOutput schema / properties / degraded
      Added value: +{
      +  "description": "Sub-queries that failed upstream, empty when every section resolved. A section listed here is unknown, not absent — a null section with no entry here genuinely has no FDA record.",
      +  "items": {
      +    "additionalProperties": false,
      +    "description": "One failed sub-query and why it failed.",
      +    "properties": {
      +      "message": {
      +        "description": "Upstream failure message for this section, truncated.",
      +        "type": "string"
      +      },
      +      "reason": {
      +        "description": "Machine-readable failure reason (e.g. rate_limited, upstream_error, query_error).",
      +        "type": "string"
      +      },
      +      "section": {
      +        "description": "Profile section whose sub-query failed.",
      +        "enum": [
      +          "identity",
      +          "label",
      +          "adverse_events",
      +          "recalls",
      +          "approval",
      +          "shortage"
      +        ],
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "section",
      +      "reason",
      +      "message"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "meta",
      -  "identity",
      -  "label",
      -  "adverse_events",
      -  "recalls",
      -  "approval",
      -  "shortage",
      -  "sectionsFound"
      -]New value: +[
      +  "meta",
      +  "identity",
      +  "label",
      +  "adverse_events",
      +  "recalls",
      +  "approval",
      +  "shortage",
      +  "degraded",
      +  "sectionsFound"
      +]
  4. Changed1 schema field changed
    • changedOutput schema / properties / label / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "dosage": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Dosage and administration (truncated)."
      -      },
      -      "indications": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Indications and usage (truncated)."
      -      },
      -      "warnings": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "description": "Warnings (truncated)."
      -      }
      -    },
      -    "required": [
      -      "indications",
      -      "warnings",
      -      "dosage"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "dosage": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ],
      +        "description": "Dosage and administration (truncated)."
      +      },
      +      "indications": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ],
      +        "description": "Indications and usage (truncated)."
      +      },
      +      "warnings": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ],
      +        "description": "Warnings (truncated) — boxed warning or warnings_and_cautions for Rx labels, falling back to the OTC-monograph warnings section."
      +      }
      +    },
      +    "required": [
      +      "indications",
      +      "warnings",
      +      "dosage"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
  5. Changed3 schema fields changed
    • changedOutput schema / properties / identity / properties / generic_name / description
      Previous value: -"Canonical generic name (openfda.generic_name) — the key used for fan-out."New value: +"Canonical generic name (openfda.generic_name) — the primary source for meta.fanOutKey."
    • addedOutput schema / properties / meta / properties / fanOutKey
      Added value: +{
      +  "description": "Canonical key the structured sub-queries (recall/enforcement, Drugs@FDA approval, shortage) ran against — the resolved generic name, falling back to a brand name, then the input term. The adverse-event sub-query instead keys off the raw input term to match heterogeneous reporter-entered values.",
      +  "type": "string"
      +}
    • changedOutput schema / properties / meta / required
      Previous value: -[
      -  "drug",
      -  "resolvedVia"
      -]New value: +[
      +  "drug",
      +  "resolvedVia",
      +  "fanOutKey"
      +]
  6. Added

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already provide readOnlyHint=true, and the description adds genuinely valuable behavior beyond that: fan-out across bounded endpoints, parallel execution, merge semantics, and especially the best-effort contract ('a miss returns null rather than failing the call'). The identifier-drift reconciliation note also explains why this tool behaves differently from naive chaining. No contradictions with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four sentences, each earning its place: the purpose and output sections, the replacement/disambiguation statement, the best-effort behavior, and the deep-dive pointer. Front-loaded with the primary action and unambiguous scoping. No filler or repetition of schema content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the output schema exists (so return structure needs no description), one fully-documented parameter, and annotations carrying the read-only safety profile, the description covers everything an agent needs: what it does, what sections it merges, when not to use it, and how partial failures behave. Complete for a complex aggregator tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% and the schema already documents the parameter with examples. The description adds meaning beyond the schema by stating that the drug name is 'Resolved once to canonical FDA identifiers, which then key every sub-query' — clarifying the resolution semantics that make the fan-out work. This exceeds the baseline 3 for high schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description states a specific verb ('Resolve one drug name to its FDA identity, then fan out... and merge into one profile') with an explicit resource and the exact content sections produced. It names the five sibling tools it replaces, so the agent can distinguish it from openfda_get_drug_label, openfda_search_adverse_events, and the other per-endpoint tools without opening their schemas.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states when to use it ('Replaces chaining openfda_get_drug_label, openfda_search_adverse_events, openfda_search_recalls, openfda_search_drug_approvals, and openfda_search_drug_shortages') and when not to ('For deep dives into any one area, use the dedicated tool'). This is unambiguous routing guidance with no inference required.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.