india_mcp
v1.0.3
Published
A Model Context Protocol (MCP) server optimized for India that provides comprehensive medical information by querying multiple authoritative medical APIs including FDA, WHO, PubMed, and RxNorm. Features India-first defaults for health statistics, Indian m
Maintainers
Readme
Medical MCP Server (India-Optimized)
A Model Context Protocol (MCP) server that provides comprehensive medical information by querying multiple authoritative medical APIs including FDA, WHO, PubMed, and RxNorm. Optimized for India with default country preferences and India-specific medical research context.
🌐 Globally Available: This package is published on npm and can be used by anyone worldwide with a single command - no cloning, no building, no complex setup!
🎯 Use Anywhere with npx
npx -y india_mcpThat's it! No installation needed. The package will be automatically downloaded from npm and run.
📦 Installation
Install Globally from npm
npm install -g india_mcpOr Use with npx (No Installation Required)
npx india_mcp🚀 Quick Start
Using with MCP Clients (Claude Desktop, Cline, etc.)
Add this configuration to your MCP settings file:
Claude Desktop Configuration
Windows: %APPDATA%\Claude\claude_desktop_config.json
macOS/Linux: ~/Library/Application Support/Claude/claude_desktop_config.json
{
"mcpServers": {
"india_mcp": {
"command": "npx",
"args": ["-y", "india_mcp"]
}
}
}Cline (VS Code Extension) Configuration
Windows: %APPDATA%\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json
macOS/Linux: ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
{
"mcpServers": {
"india_mcp": {
"command": "npx",
"args": ["-y", "india_mcp"]
}
}
}Alternative: Using Globally Installed Package
If you've installed globally with npm install -g india_mcp:
{
"mcpServers": {
"india_mcp": {
"command": "node",
"args": ["<path-to-global-npm>/node_modules/india_mcp/build/index.js"]
}
}
}Find your global npm path:
- Windows:
%APPDATA%\npm\node_modules\india_mcp\build\index.js - macOS/Linux: Run
npm root -gto find the path
Direct Command Line Usage
# Default stdio mode (for MCP clients)
india_mcp
# HTTP mode (for testing)
india_mcp --http
# HTTP mode with custom port
india_mcp --http --port=3000🇮🇳 India-First Configuration
This server is configured with India as the default country preference:
- Health Statistics: Automatically defaults to India (IND) for WHO health indicators
- Medical Literature: Option to include India-specific research context in PubMed searches (enabled by default)
- Clinical Guidelines: Includes Indian medical organizations (ICMR, IMA, etc.) in guideline searches
- Regional Focus: Prioritizes India-relevant medical data while maintaining global access
You can always override these defaults by specifying different country codes or disabling India context.
🔒 Security Features
Localhost-Only Binding: This server is configured for maximum security with localhost-only access:
- Stdio Mode (Default): Inherently localhost-only process communication
- HTTP Mode: Binds to
127.0.0.1only, blocks all external connections - IP Filtering: Validates all incoming connections against localhost addresses
- CORS Restrictions: Only allows localhost origins
- Security Logging: All blocked connection attempts are logged
See SECURITY.md for detailed security configuration.
Features
This MCP server offers specialized tools for querying medical information from reliable sources:
💊 Drug Information Tools
search-drugs
Search for drug information using the FDA database.
Input:
query(string): Drug name to search for (brand name or generic name)limit(optional, number): Number of results to return (1-10, default: 5)
Output:
- Drug information including brand name, generic name, manufacturer, route, dosage form, and purpose
Example:
Drug Search Results for "Advil"
Found 1 drug(s)
1. **ADVIL**
Generic Name: IBUPROFEN
Manufacturer: PFIZER CONSUMER HEALTHCARE
Route: ORAL
Dosage Form: TABLET
Purpose: For temporary relief of minor aches and pains...
Last Updated: 20210902get-drug-details
Get detailed information about a specific drug by NDC (National Drug Code).
Input:
ndc(string): National Drug Code (NDC) of the drug
Output:
- Comprehensive drug information including warnings, drug interactions, and clinical pharmacology
📊 Health Statistics Tools
get-health-statistics
Get health statistics and indicators from WHO Global Health Observatory (defaults to India).
Input:
indicator(string): Health indicator to search for (e.g., 'Life expectancy', 'Mortality rate')country(optional, string): Country code (e.g., 'IND', 'USA', 'GBR') - defaults to 'IND' (India)limit(optional, number): Number of results to return (1-10, default: 5)
Output:
- Health statistics with values, ranges, and temporal data
Example:
Health Statistics: Life expectancy at birth (years)
Country: IND
Found 5 data points
1. **IND** (2019)
Value: 69.7 years
Numeric Value: 69.7
Date: 2019-12-31🔬 Medical Literature Tools
search-medical-literature
Search for medical research articles in PubMed (India-focused by default).
Input:
query(string): Medical topic or condition to search formax_results(optional, number): Maximum number of articles to return (1-10, default: 5)include_india_context(optional, boolean): Include India-specific research context in search (default: true)
Output:
- Medical research articles with titles, PMIDs, journals, and publication dates
Note: By default, searches include India-specific context to prioritize research relevant to Indian healthcare. Set include_india_context to false for global-only results.
Example:
Medical Literature Search: "diabetes treatment"
Found 5 article(s)
1. **Novel Approaches to Diabetes Management**
PMID: 12345678
Journal: New England Journal of Medicine
Publication Date: 2024-01-15search-google-scholar
Search for academic research articles using Google Scholar.
Input:
query(string): Academic topic or research query to search for
Output:
- Academic research articles with titles, authors, abstracts, journals, years, citations, and URLs
Example:
Google Scholar Search: "machine learning healthcare"
Found 5 article(s)
1. **Machine Learning in Healthcare: A Systematic Review**
Authors: Smith J, Johnson A - Journal of Medical AI
Year: 2023
Citations: Cited by 45
URL: https://scholar.google.com/...
Abstract: This systematic review examines the application of machine learning...Note: This tool uses web scraping to access Google Scholar since it doesn't provide a public API. It includes rate limiting protection and stealth measures to avoid detection.
🏥 Drug Nomenclature Tools
search-drug-nomenclature
Search for drug information using RxNorm (standardized drug nomenclature).
Input:
query(string): Drug name to search for in RxNorm database
Output:
- Standardized drug information with RxCUI codes, synonyms, and term types
🩺 Clinical Guidelines Tools
search-clinical-guidelines
Search for clinical guidelines and practice recommendations from medical organizations (includes Indian medical organizations by default).
Input:
query(string): Medical condition or topic to search for guidelinesorganization(optional, string): Specific medical organization to filter by (e.g., 'Indian Council of Medical Research', 'ICMR', 'WHO', 'American Heart Association')include_india_context(optional, boolean): Include Indian medical organizations and context in search (default: true)
Output:
- Clinical guidelines with organization, year, category, evidence level, and URLs
Supported Indian Organizations:
- Indian Council of Medical Research (ICMR)
- Ministry of Health and Family Welfare India
- Indian Medical Association (IMA)
- Cardiological Society of India
- Indian Academy of Pediatrics
- Association of Physicians of India
- Endocrine Society of India
- Indian Psychiatric Society
Note: By default, searches prioritize Indian medical guidelines and organizations. Set include_india_context to false for global-only results.
💊 Drug Interaction Tools
check-drug-interactions
Check for potential drug-drug interactions between two medications.
Input:
drug1(string): First drug namedrug2(string): Second drug name
Output:
- Potential drug interactions, severity levels, and recommendations
Installation
- Clone this repository:
git clone <repository-url>
cd medical-mcp- Install dependencies:
npm install- Build the project:
npm run buildUsage
Running the Server
Start the MCP server:
npm startThe server runs on stdio and can be connected to any MCP-compatible client.
Example Queries
Here are some example queries you can make with this MCP server:
Search for Drug Information
{
"tool": "search-drugs",
"arguments": {
"query": "Tylenol",
"limit": 5
}
}Get Drug Details by NDC
{
"tool": "get-drug-details",
"arguments": {
"ndc": "00071015527"
}
}Get Health Statistics
{
"tool": "get-health-statistics",
"arguments": {
"indicator": "Life expectancy at birth (years)",
"country": "IND",
"limit": 5
}
}Note: The country parameter defaults to 'IND' (India), so you can omit it to get India's statistics:
{
"tool": "get-health-statistics",
"arguments": {
"indicator": "Life expectancy at birth (years)",
"limit": 5
}
}Search Medical Literature
{
"tool": "search-medical-literature",
"arguments": {
"query": "COVID-19 treatment",
"max_results": 10
}
}Search Drug Nomenclature
{
"tool": "search-drug-nomenclature",
"arguments": {
"query": "aspirin"
}
}API Endpoints
This MCP server integrates with the following medical APIs:
FDA API
GET /drug/label.json- Drug labeling information- Search by brand name, generic name, or NDC
- Provides safety information, warnings, and clinical data
WHO Global Health Observatory API
GET /api/Indicator- Health statistics and indicators- Global health data with country-specific information
- Temporal data for trend analysis
PubMed API
GET /esearch.fcgi- Search for medical articlesGET /efetch.fcgi- Retrieve article details- Access to millions of medical research papers
RxNorm API
GET /REST/drugs.json- Standardized drug nomenclature- Drug name standardization and relationships
- Clinical drug information
Google Scholar (Web Scraping)
- Web scraping of Google Scholar search results
- Academic research article discovery
- Citation and publication information
- Note: Uses Puppeteer for browser automation with anti-detection measures
Data Sources
FDA (Food and Drug Administration)
- Source: Official FDA drug labeling database
- Coverage: All FDA-approved drugs in the United States
- Data: Drug safety, efficacy, dosage, warnings, and interactions
- Update Frequency: Real-time as drugs are approved or labeling changes
WHO (World Health Organization)
- Source: Global Health Observatory database
- Coverage: Global health statistics from 194 countries
- Data: Life expectancy, mortality rates, disease prevalence, and health indicators
- Update Frequency: Annual updates with historical data
PubMed (National Library of Medicine)
- Source: MEDLINE database of medical literature
- Coverage: Over 30 million citations from medical journals
- Data: Research articles, clinical studies, and medical reviews
- Update Frequency: Daily updates as new articles are published
RxNorm (National Library of Medicine)
- Source: Standardized drug nomenclature system
- Coverage: Clinical drugs available in the United States
- Data: Drug names, codes, relationships, and clinical information
- Update Frequency: Weekly updates
Google Scholar (Web Scraping)
- Source: Google Scholar academic search engine
- Coverage: Academic papers, theses, books, and abstracts across all disciplines
- Data: Research articles, citations, authors, journals, and publication dates
- Update Frequency: Real-time as new papers are indexed
- Note: Access via web scraping with rate limiting protection
Error Handling
The server includes comprehensive error handling:
- Network errors are caught and reported with descriptive messages
- Invalid queries return appropriate error messages
- Rate limiting and API errors are handled gracefully
- Fallback responses when specific APIs are unavailable
Web Scraping Implementation
The Google Scholar integration uses Puppeteer for web scraping with the following features:
Anti-Detection Measures
- Stealth Mode: Browser launched with multiple flags to avoid detection
- User Agent Spoofing: Realistic browser user agent strings
- Random Delays: Built-in delays between requests to avoid rate limiting
- Header Spoofing: Realistic HTTP headers to appear as a regular browser
- Viewport Settings: Standard desktop viewport dimensions
Robust Parsing
- Multiple Selectors: Uses various CSS selectors to handle different Google Scholar layouts
- Fallback Strategies: Multiple parsing approaches for different page structures
- Error Recovery: Graceful handling of missing elements or changed page structures
- Data Validation: Filters out incomplete or invalid results
Rate Limiting Protection
- Random Delays: 1-3 second random delays between requests
- Browser Management: Proper browser cleanup to prevent resource leaks
- Timeout Handling: Configurable timeouts for network requests
- Error Recovery: Automatic retry logic for failed requests
🚀 Usage
Stdio Mode (Default - Most Secure)
# Build and run in stdio mode (inherently localhost-only)
npm run build
npm start
# Or directly
node build/index.jsHTTP Mode (Localhost-Only)
# HTTP server on localhost only (port 3000)
npm run start:http
# Custom port
npm run start:http:port
# or
node build/index.js --http --port=8080
# Test localhost access
curl http://localhost:3000/infoDevelopment Mode
# Build and run stdio
npm run dev
# Build and run HTTP
npm run dev:http🤖 Claude Desktop Integration
Setup Instructions
1. Install and Build the Server
# Clone the repository
git clone https://github.com/JamesANZ/medical-mcp.git
cd medical-mcp
# Install dependencies
npm install
# Build the server
npm run build2. Configure Claude Desktop
Create or edit your Claude Desktop configuration file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"medical-mcp": {
"command": "node",
"args": ["/path/to/medical-mcp/build/index.js"],
"cwd": "/path/to/medical-mcp"
}
}
}Replace the paths with your actual installation directory:
For users with NVM (Node Version Manager):
{
"mcpServers": {
"medical-mcp": {
"command": "/Users/yourusername/.nvm/versions/node/v22.17.0/bin/node",
"args": [
"/Users/yourusername/Documents/projects/medical-mcp/build/index.js"
]
}
}
}For users with system Node.js:
{
"mcpServers": {
"medical-mcp": {
"command": "node",
"args": ["/Users/yourusername/medical-mcp/build/index.js"],
"cwd": "/Users/yourusername/medical-mcp"
}
}
}To find your Node.js path:
# If using NVM
which node
# Example output: /Users/yourusername/.nvm/versions/node/v22.17.0/bin/node
# If using system Node.js
which node
# Example output: /usr/local/bin/node3. Restart Claude Desktop
- Close Claude Desktop completely
- Reopen Claude Desktop
- The Medical MCP Server will start automatically
Available Medical Tools in Claude
Once connected, you'll have access to these medical tools:
🔍 Search Tools
search-drugs- Search FDA drug databasesearch-pubmed-articles- Search medical literaturesearch-google-scholar- Search academic researchsearch-medical-databases- Comprehensive multi-database searchsearch-medical-journals- Search top medical journals
💊 Drug Information Tools
get-drug-by-ndc- Get drug details by NDC codecheck-drug-interactions- Check drug interactionsget-drug-safety-info- Get drug safety information
🏥 Clinical Tools
generate-differential-diagnosis- Generate differential diagnosesget-diagnostic-criteria- Get diagnostic criteria for conditionsget-risk-calculators- Get clinical risk calculatorsget-lab-values- Get normal lab value ranges
📊 Health Data Tools
get-health-indicators- Get WHO health statisticssearch-rxnorm-drugs- Search RxNorm drug databasesearch-clinical-guidelines- Search clinical guidelines
Example Claude Conversations
Drug Information Query
User: "What are the side effects of metformin and can it interact with lisinopril?"
Claude will use:
- search-drugs for metformin information
- check-drug-interactions for metformin + lisinopril
- get-drug-safety-info for detailed safety dataClinical Decision Support
User: "A 45-year-old patient presents with chest pain, shortness of breath, and diaphoresis. What should I consider?"
Claude will use:
- generate-differential-diagnosis for possible conditions
- get-diagnostic-criteria for specific diagnostic criteria
- search-medical-databases for latest researchResearch and Literature Review
User: "Find recent research on COVID-19 treatment protocols"
Claude will use:
- search-pubmed-articles for medical literature
- search-medical-journals for top-tier research
- search-google-scholar for additional academic sources🔒 Security Features in Claude
- Localhost-Only: Server runs locally, no external access
- Process Isolation: Medical data stays on your machine
- No Data Storage: No medical data is stored locally
- Dynamic Data: All information retrieved in real-time
- Audit Logging: All queries are logged for transparency
Troubleshooting
Server Won't Start
# Check if the server builds correctly
npm run build
# Test the server directly
node build/index.js
# Check for port conflicts
lsof -i :3000Claude Can't Connect
- Verify the configuration file path is correct
- Ensure the server executable path is absolute
- Check that Node.js is in your PATH
- Restart Claude Desktop after configuration changes
Permission Issues
# Make sure the executable has proper permissions
chmod 755 build/index.js
# On macOS, you might need to allow Node.js in Security & PrivacyNetwork Issues
- The server uses localhost-only binding for security
- No external network access required for the server itself
- Medical data is fetched from external APIs when needed
Best Practices
For Medical Professionals
- Always verify information through multiple sources
- Use as a starting point for research, not final decisions
- Follow established clinical guidelines
- Document your decision-making process
For Students and Researchers
- Use for literature reviews and research
- Cross-reference with primary sources
- Understand the limitations of AI-generated summaries
- Always cite original sources
For General Users
- Use for educational purposes only
- Never replace professional medical advice
- Consult healthcare providers for medical decisions
- Be aware of information limitations
Advanced Configuration
Custom Port (if needed)
{
"mcpServers": {
"medical-mcp": {
"command": "node",
"args": ["/path/to/medical-mcp/build/index.js", "--http", "--port=3001"],
"cwd": "/path/to/medical-mcp"
}
}
}Environment Variables
# Set custom API timeouts
export MCP_TIMEOUT=30000
# Set custom user agent
export MCP_USER_AGENT="Medical-Research-Tool/1.0"🔒 Security Verification
Test Localhost Access
# Should work (localhost)
curl http://localhost:3000/info
# Should be blocked (external IP)
curl http://YOUR_EXTERNAL_IP:3000/info
# Returns: "Access denied: This server is restricted to localhost only"Check Binding
# Verify server is bound to localhost only
netstat -an | grep :3000
# Should show: 127.0.0.1:3000 (not 0.0.0.0:3000)Medical Disclaimer
Important: This MCP server provides information from authoritative medical sources but should not be used as a substitute for professional medical advice, diagnosis, or treatment. Always consult with qualified healthcare professionals for medical decisions.
- The information provided is for educational and informational purposes only
- Drug information may not be complete or up-to-date for all medications
- Health statistics are aggregated data and may not reflect individual circumstances
- Medical literature should be interpreted by qualified healthcare professionals
🌐 Access from Anywhere
This MCP server is published on npm and can be accessed globally by anyone:
npm Package URL
- Package: https://www.npmjs.com/package/india_mcp
- Install:
npm install -g india_mcp - Run:
india_mcpornpx india_mcp
Using in Your Projects
Anyone worldwide can use this MCP server by adding it to their MCP client configuration. The server will be automatically downloaded from npm when first accessed.
Example for any MCP client:
{
"mcpServers": {
"india_mcp": {
"command": "npx",
"args": ["-y", "india_mcp"]
}
}
}For Developers
If you want to integrate this server into your applications:
import { spawn } from 'child_process';
// Spawn the MCP server
const mcpServer = spawn('npx', ['-y', 'india_mcp']);
// Handle stdio communication
mcpServer.stdout.on('data', (data) => {
console.log('Server output:', data.toString());
});📊 Package Statistics
- Package Name:
india_mcp - Latest Version: Check npm
- Downloads: Updated weekly on npm
- Author: surendirakrishna
Dependencies
@modelcontextprotocol/sdk- MCP SDK for server implementationsuperagent- HTTP client for API requestspuppeteer- Browser automation for web scraping Google Scholarzod- Schema validation for tool parameters
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
Support
If you encounter any issues or have questions:
- GitHub Issues: Report an issue
- npm Package: https://www.npmjs.com/package/india_mcp
- Email: Contact the maintainer through npm profile
License
This project is licensed under the ISC License - see the LICENSE.md file for details.
