mcp-pubmed
一个用来让本地agent利用api高效爬取pubmed论文的mcp工具
claude mcp add --transport stdio hhx465453939-mcp-pubmed-server node src/index.js \ --env HTTP_PROXY="" \ --env HTTPS_PROXY="" \ --env PUBMED_EMAIL="your-email@example.com" \ --env ABSTRACT_MODE="deep" \ --env FULLTEXT_MODE="enabled" \ --env PROXY_ENABLED="disabled" \ --env ENDNOTE_EXPORT="enabled" \ --env PUBMED_API_KEY="your-pubmed-api-key"
How to use
This MCP server provides PubMed data to your LLM workflows. It exposes a set of tooling endpoints that allow you to search PubMed, fetch detailed records, extract key insights, and manage full-text availability and EndNote exports. Typical usage involves running the server locally or in your environment, then configuring your MCP client (e.g., VS Code extension, Cherry Studio, Claude Desktop/Code) to point at the local node process. The included tools include pubmed_search for querying literature, pubmed_get_details for retrieving detailed records, pubmed_extract_key_info for structured extraction, and pubmed_batch_query to optimize batch requests. You can also check full-text status, download Open Access PDFs when available, and manage EndNote RIS/BibTeX exports. The server supports proxy configuration and adjustable abstract/full-text modes to balance context length with retrieval depth.
How to install
Prerequisites:
- Node.js v18.0.0+ installed
- npm installed
- Access to PubMed API key and a registered email
Steps:
- Clone the repository and navigate to the project
git clone https://github.com/your-repo/mcp-pubmed-server.git
cd mcp-pubmed-server
- Install dependencies
npm install
- Create and configure environment variables
cp .env.example .env
Edit .env to include:
PUBMED_API_KEY=your-pubmed-api-key
PUBMED_EMAIL=your-email@example.com
ABSTRACT_MODE=deep
FULLTEXT_MODE=enabled
PROXY_ENABLED=disabled
HTTP_PROXY=
HTTPS_PROXY=
ENDNOTE_EXPORT=enabled
- Run the MCP server (as a local MCP server)
node src/index.js
- Verify the server starts and outputs a ready message such as:
PubMed Data Server v2.0 running on stdio
- Optional: configure your MCP client adapters (VS Code, Cherry Studio, Claude) with the provided templates in the README to connect to this server.
Additional notes
Tips and notes:
- The server exposes PubMed-related tools via JSON interfaces; ensure your client config uses the same command and environment as shown in the README examples.
- If you enable FULLTEXT_MODE, the server will attempt to detect and download OA full texts where available; ensure your network allows access.
- Use ABSTRACT_MODE to balance context length; quick mode reduces the abstract length for faster queries, while deep mode provides longer abstracts when context window permits.
- PROXY_ENABLED and related HTTP_PROXY/HTTPS_PROXY settings help in restricted networks; set appropriate values if you’re behind a corporate proxy.
- EndNote export (RIS/BibTeX) can be disabled by setting ENDNOTE_EXPORT to disabled if you don’t need exports.
- For MCP client integrations, you can copy the server configuration into your client’s mcpServers section to enable seamless cross-tool usage.
Related MCP Servers
zen
Selfhosted notes app. Single golang binary, notes stored as markdown within SQLite, full-text search, very low resource usage
MCP -Deepseek_R1
A Model Context Protocol (MCP) server implementation connecting Claude Desktop with DeepSeek's language models (R1/V3)
mcp-fhir
A Model Context Protocol implementation for FHIR
mcp
Inkdrop Model Context Protocol Server
mcp-appium-gestures
This is a Model Context Protocol (MCP) server providing resources and tools for Appium mobile gestures using Actions API..
dubco -npm
The (Unofficial) dubco-mcp-server enables AI assistants to manage Dub.co short links via the Model Context Protocol. It provides three MCP tools: create_link for generating new short URLs, update_link for modifying existing links, and delete_link for removing short links.