dailymed-mcp-server

RowanErasmus/dailymed-mcp-server

3.2

If you are the rightful owner of dailymed-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

The MCP Server for DailyMed provides access to comprehensive drug information from the DailyMed database via the National Library of Medicine's web services API.

Tools
  1. search_drugs

    Search for drugs by name or active ingredient

  2. search_spls

    Search for Structured Product Labels by title

  3. get_drug_details

    Get detailed information about a specific drug by SET ID

  4. get_drug_history

    Get version history for a specific drug

  5. get_drug_ndcs

    Get NDC codes for a specific drug

  6. get_drug_packaging

    Get packaging information for a specific drug

  7. get_drug_media

    Get media links (images, documents) for a specific drug

  8. get_download_links

    Get ZIP and PDF download links for a specific drug

  9. get_all_drug_names

    Get all available drug names

  10. get_all_drug_classes

    Get all available drug classes

  11. get_all_ndcs

    Get all available NDC codes

  12. get_all_rxcuis

    Get all available RxCUI codes

  13. get_all_uniis

    Get all available UNII codes

  14. get_all_application_numbers

    Get all available FDA application numbers

DailyMed MCP Server

A Model Context Protocol (MCP) server that provides access to the DailyMed API for comprehensive drug information.

About DailyMed

DailyMed is the official FDA database containing drug labeling information for approved prescription/nonprescription drugs, biologics, and medical devices. It provides structured, up-to-date drug information in multiple formats with cross-references to RxNorm and pharmacologic classifications.

Installation

git clone <repository-url>
cd dailymed-mcp-server
npm install
npm run build

Optional: Download mapping files from DailyMed Mapping Files and place in project root:

  • pharmacologic_class_mappings.txt
  • rxnorm_mappings.txt

Usage

npm start              # Production
npm run dev           # Development with hot reload

Key Features

Search Tools

  • search_spls - Search Structured Product Labels with advanced filtering and pagination
  • search_drug_names - Search drug names with manufacturer and name type filters
  • search_rxcuis - Search RxCUI codes with term type filtering
  • search_drug_classes - Search pharmacologic drug classes
  • search_application_numbers - Search FDA application numbers
  • search_uniis - Search UNII codes with advanced filters

Drug Information

  • get_drug_details - Complete drug information by SET ID
  • get_drug_history - Version history for drugs
  • get_drug_ndcs - NDC codes for specific drugs
  • get_drug_packaging - Packaging information
  • get_drug_media - Media links (images, documents)

Database Access

  • get_all_* - Paginated access to drug names, classes, NDCs, RxCUIs, UNIIs, application numbers
  • get_dailymed_context - Database information and capabilities

Enhanced Mapping (when mapping files present)

  • search_by_rxnorm_mapping - Search RxNorm mappings by drug name
  • get_*_mappings_for_setid - Get mappings for specific drugs
  • search_drugs_by_pharmacologic_class - Find drugs by pharmacologic class

Advanced SPL Search

Simple Search

{
  "query": "aspirin",
  "page": 1,
  "pageSize": 25
}

Advanced Search

{
  "manufacturer": "Pfizer",
  "boxed_warning": true,
  "published_date": "2023-01-01",
  "published_date_comparison": "gte",
  "page": 1,
  "pageSize": 50
}

Available filters: application_number, boxed_warning, dea_schedule_code, drug_name, name_type, labeler, manufacturer, ndc, rxcui, unii_code, published_date, and more.

Pagination

All search and list tools support pagination with consistent response format:

{
  "data": [...],
  "pagination": {
    "page": 1,
    "pageSize": 25,
    "totalResults": 150,
    "totalPages": 6,
    "hasNextPage": true,
    "hasPreviousPage": false
  }
}

Claude Desktop Configuration

{
  "mcpServers": {
    "dailymed": {
      "command": "node",
      "args": ["/path/to/dailymed-mcp-server/dist/index.js"],
      "cwd": "/path/to/dailymed-mcp-server"
    }
  }
}

API Information

Development

npm run build    # Build TypeScript
npm run dev      # Development mode

Project Structure:

src/
ā”œā”€ā”€ clients/           # Modular API clients
ā”œā”€ā”€ types/            # TypeScript type definitions
ā”œā”€ā”€ utils/            # Utilities and helpers
ā”œā”€ā”€ index.ts          # MCP server implementation
└── tools.ts          # Tool definitions

License

MIT License