Skip to main content

PubMed MCP Server

An MCP (Model Context Protocol) server that provides tools for searching and retrieving biomedical literature from PubMed via the NCBI E-utilities API.

Features

Tool Description
search_pubmed Search PubMed with a query string, returns article summaries
fetch_article Fetch full metadata and abstract for a specific PMID
fetch_abstract Get just the abstract text for a PMID
verify_citation Check if a PMID matches a given title (returns similarity score)
search_by_title Find the correct PMID for a given article title

Installation

From PyPI

pip install suppevo-pubmed-mcp

From source

git clone https://github.com/gomezmera/suppevo-pubmed-mcp.git
cd suppevo-pubmed-mcp/pubmed
pip install -e .

Configuration

NCBI API Key (recommended)

An API key increases your rate limit from 3 requests/sec to 10 requests/sec.

  1. Create a free NCBI account at NCBI
  2. Go to Account Settings and generate an API key
  3. Set the environment variable:
export NCBI_API_KEY="your-api-key-here"

Or add it to a .env file in your home directory (~/.env):

NCBI_API_KEY=your-api-key-here

The server will automatically load it from ~/.env if present.

Running the Server

Standalone

# If installed via pip
suppevo-pubmed-mcp

# Or run directly with FastMCP
fastmcp run server.py

With Kiro

Add to your .kiro/settings/mcp.json:

{
  "mcpServers": {
    "pubmed": {
      "command": "python",
      "args": ["/path/to/suppevo-pubmed-mcp/pubmed/server.py"],
      "env": {
        "NCBI_API_KEY": "your-api-key-here"
      }
    }
  }
}

Or if installed from PyPI:

{
  "mcpServers": {
    "pubmed": {
      "command": "uvx",
      "args": ["suppevo-pubmed-mcp"],
      "env": {
        "NCBI_API_KEY": "your-api-key-here"
      }
    }
  }
}

With Claude Desktop

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "pubmed": {
      "command": "uvx",
      "args": ["suppevo-pubmed-mcp"],
      "env": {
        "NCBI_API_KEY": "your-api-key-here"
      }
    }
  }
}

Usage Examples

Once connected to an MCP client, you can use natural language:

  • "Search PubMed for vitamin D supplementation meta-analysis 2024"
  • "Fetch the full details for PMID 30415628"
  • "Verify that PMID 17846391 is about vitamin D supplementation and total mortality"
  • "Find the PMID for the article titled 'Effect of zinc supplementation on C-reactive protein'"
  • "Get the abstract for PMID 25927176"

Query Syntax

The search_pubmed tool supports PubMed's full query syntax:

# Basic search
vitamin D supplementation

# Field-specific
curcumin AND inflammation[Title]

# Author search
Prasad AS[Author] AND zinc

# Date range
omega-3 AND cardiovascular[Title] AND 2020:2024[dp]

# MeSH terms
"Zinc/therapeutic use"[MeSH]

Rate Limits

Configuration Rate Limit
Without API key 3 requests/second
With API key 10 requests/second

The server automatically throttles requests to stay within limits. NCBI may temporarily block IPs that exceed these limits.

Development

# Clone and install in development mode
git clone https://github.com/gomezmera/suppevo-pubmed-mcp.git
cd suppevo-pubmed-mcp/pubmed
pip install -e .

# Run the server
python server.py

Publishing

See RELEASING.md for instructions on publishing to PyPI.

License

MIT

Metadata

Release files for suppevo-pubmed-mcp 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for suppevo-pubmed-mcp 1.0.1
File Size Uploaded Provenance
suppevo_pubmed_mcp-1.0.1.tar.gz 6.3 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for suppevo-pubmed-mcp 1.0.1
File Interpreter ABI Platform
suppevo_pubmed_mcp-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 13.1 kB

Release files / suppevo_pubmed_mcp-1.0.1.tar.gz

Download URL suppevo_pubmed_mcp-1.0.1.tar.gz
Size 6.3 kB
Tags Source
SHA-256 checksum
How to use checksums
dad98eea5ea8373a0b099f56aa3c9fa46f2eda2e93d7f8ad082b9a92978deb8c
BLAKE2b-256 checksum
How to use checksums
1295946f8eddb49695f937fffd2cc16cceca1afba7a3924b24e1b9bdb4306f11
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.3

Release files / suppevo_pubmed_mcp-1.0.1-py3-none-any.whl

Download URL suppevo_pubmed_mcp-1.0.1-py3-none-any.whl
Size 6.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
47c303965a5727a9c20efb5f7dabf94ba2d9200abfb0b2904ef06f8c8c0d2365
BLAKE2b-256 checksum
How to use checksums
991e7bb2cd287bf83d3142080ebd37e5a61f8c678eeec417ae53244fc4b7a6f0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.3

Security for suppevo-pubmed-mcp 1.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page