PubMed API and MCP server for AI agents
Let Claude, ChatGPT or your own agent read PubMed. No PubMed API key needed.
Add to your agent
Paste this into Claude Code, Cursor, Codex or any agent. It adds the server itself.
Read https://bowmark.ai/sites/pubmed.md and add Bowmark's PubMed MCP server to my agent.Run this in a terminal, then sign in when the browser opens. Claude Code keeps its own sign-in (a claude.ai sign-in does not carry over), so add only this one server. Adding the Bowmark plugin as well lists every tool twice.
claude mcp add --transport http bowmark-pubmed https://api.bowmark.ai/mcp/site/pubmedPress the button, or add this to ~/.cursor/mcp.json.
{
"mcpServers": {
"bowmark-pubmed": {
"url": "https://api.bowmark.ai/mcp/site/pubmed"
}
}
}Press the button, or run this in a terminal.
code --add-mcp '{"name":"bowmark-pubmed","type":"http","url":"https://api.bowmark.ai/mcp/site/pubmed"}'Run this in a terminal.
codex mcp add bowmark-pubmed --url https://api.bowmark.ai/mcp/site/pubmedIn Claude, open Plugins → Add → Add custom connector, paste this URL, and pick Sign in now.
https://api.bowmark.ai/mcp/site/pubmedIn ChatGPT, open Plugins, press +, choose Add custom MCP server and paste this URL.
https://api.bowmark.ai/mcp/site/pubmedAny MCP client that takes a remote (streamable HTTP) server: give it this URL.
https://api.bowmark.ai/mcp/site/pubmedFunctions
Open a function to see its parameters and run it with your own API key.
getArticleReads one PubMed article by PMID.POST /v1/sites/pubmed/getArticle
Parameters
curl -X POST https://api.bowmark.ai/v1/sites/pubmed/getArticle \ -H "Authorization: Bearer $BOWMARK_API_KEY" \ -H "Content-Type: application/json" \ -d '{"pmid":"31978945"}'import { bowmark } from "@bowmark/web"; const result = await bowmark.providers.pubmed.getArticle("31978945");import asyncio from bowmark_web import bowmark result = asyncio.run(bowmark.providers.pubmed.getArticle("31978945"))Responsereturns pubmedArticleDetailinterface pubmedArticleDetail { pmid: string; // "31978945", pass to getArticle title: string; authors: string[]; // e.g. "Zhu N" journal: string | null; date: string | null; // as PubMed prints it, e.g. "2026 Nov 26" doi: string | null; url: string; // https://pubmed.ncbi.nlm.nih.gov/<pmid>/ abstract: string | null; // null when PubMed holds none; sections are labelled publicationTypes: string[]; meshTerms: string[]; }searchSearches PubMed's biomedical literature index with PubMed query syntax, newest or most relevant first, returning typed article rows (PMID, title…POST /v1/sites/pubmed/search
Parameters
curl -X POST https://api.bowmark.ai/v1/sites/pubmed/search \ -H "Authorization: Bearer $BOWMARK_API_KEY" \ -H "Content-Type: application/json" \ -d '{"query":"aspirin","opts":{}}'import { bowmark } from "@bowmark/web"; const result = await bowmark.providers.pubmed.search("aspirin", {});import asyncio from bowmark_web import bowmark result = asyncio.run(bowmark.providers.pubmed.search("aspirin", {}))Responsereturns pubmedSearchResultsinterface pubmedArticle { pmid: string; // "31978945", pass to getArticle title: string; authors: string[]; // e.g. "Zhu N" journal: string | null; date: string | null; // as PubMed prints it, e.g. "2026 Nov 26" doi: string | null; url: string; // https://pubmed.ncbi.nlm.nih.gov/<pmid>/ } interface pubmedSearchResults { query: string; totalResults: number; // the full match count, not just articles.length articles: pubmedArticle[]; }