@cyanheads/biorxiv-mcp-server

中文文档
0.5.1发布于 2026/10/30Apache-2.0TypeScriptES Module近 30 天下载 2481

Search and retrieve bioRxiv and medRxiv preprints — by DOI, date interval, or keyword — via MCP. STDIO or Streamable HTTP.

原始使用文档
文档目录20 节
  1. Overview
  2. Tools
  3. Capability reference
  4. biorxiv_get_preprint tool
  5. biorxiv_list_recent tool
  6. biorxiv_search_preprints tool
  7. biorxiv_get_published_version tool
  8. biorxiv_list_published_versions tool
  9. biorxiv_get_fulltext tool
  10. biorxiv_list_categories tool
  11. Features
  12. Getting started
  13. Configuration
  14. Running the server
  15. Local development
  16. Docker
  17. Project structure
  18. Development guide
  19. Contributing
  20. License

@cyanheads/biorxiv-mcp-server

Search and retrieve bioRxiv and medRxiv preprints — by DOI, date interval, or keyword — via MCP. STDIO or Streamable HTTP.

7 Tools

Version License Docker MCP SDK npm TypeScript Bun

Install in Claude Desktop Install in Cursor Install in VS Code

Framework

Public Hosted Server: https://biorxiv.caseyjhand.com/mcp


Overview

bioRxiv and medRxiv preprints, metadata and full text. Search by keyword and author, browse a date interval (optionally by subject), fetch any preprint by DOI, and see which preprints went on to journal publication.

Tools

ToolDescription
biorxiv_get_preprintFetch full metadata, abstract, revision history, and journal crosswalk for one or more preprints by DOI
biorxiv_list_recentList preprints posted or updated within a date interval, with optional server, category, and funder filters
biorxiv_search_preprintsSearch preprints by keyword and/or author via EuropePMC for relevance ranking, enriched with bioRxiv/medRxiv metadata
biorxiv_get_published_versionResolve a preprint DOI to its journal publication record (journal DOI, name, published date), or a journal article's DOI to the preprint it was posted as
biorxiv_list_published_versionsList preprints that appeared as journal articles within a journal publication-date interval, whenever they were posted, optionally from one publisher
biorxiv_get_fulltextRetrieve a preprint's full text as best-effort Markdown extracted from its rendered HTML article page
biorxiv_list_categoriesList valid subject category strings for bioRxiv and medRxiv

Capability reference

biorxiv_get_preprint tool

  • Takes DOIs bare or pasted (https://doi.org/…, doi:…, a biorxiv.org/medrxiv.org article URL, a vN or .full suffix), scoped to biorxiv, medrxiv, or both (default both)
  • Accepts up to 200 entries and looks up the first 10 distinct DOIs; the rest come back in unprocessed[] to pass in another call. A repeated DOI is looked up once, and every list keeps input order
  • Each preprint returns its full revision history in revisions[] — title, authors, category, license, awards, jatsxmlUrl, publishedJournalDoi once accepted, and the server it was found on (biorxiv or medrxiv, ready to pass back as server). Funder names are omitted because the upstream API misattributes them
  • The abstract sits on the latest revision only: the upstream API keeps one abstract per preprint. An earlier revision's own abstract is on its article page, through biorxiv_get_fulltext with version
  • A DOI that fails lands in failed[] with a reason (not_found, invalid_doi_format, upstream_unavailable, rate_limited) and a retryable flag; not_found only when every attempted server answered

biorxiv_list_recent tool

  • Takes a start_date/end_date interval, server (default both), and optional category (a value from biorxiv_list_categories) and bioRxiv-only funder (a ROR ID) filters; a filter that cannot be applied raises invalid_category or invalid_funder
  • Pages of 30 advance with an integer cursor, tracked per server ({ biorxiv: { cursor, total, newPreprints }, medrxiv: { cursor, total, newPreprints } }); a cursor past the last page is marked exhausted: true, and a server that did not answer is named in failed[]
  • Rows are revisions: total counts every version posted in the interval, while newPreprints counts the preprints whose first version posted in it, as the API reports it (absent when the API sends no count)
  • Abstracts are omitted by default; include_abstract: true adds them. Each is the preprint's latest-revision abstract, even on a row for an earlier revision

biorxiv_search_preprints tool

  • Takes query and/or author, optional date_from/date_to and server (default both); up to 100 results per page (default 25; a larger limit returns 100 with a notice), paged with cursor_mark
  • EuropePMC ranks the matches (it indexes new preprints within 1–2 days of posting) and the bioRxiv/medRxiv API enriches them with the same fields as biorxiv_get_preprint; a record left with EuropePMC metadata only carries enriched: false and an enrichment_error (service_error, rate_limited, not_found), with partial_results set
  • Abstracts are included by default; include_abstract: false drops them for a response about a third the size

biorxiv_get_published_version tool

  • Takes one DOI and server (default both): a preprint DOI (10.1101/, 10.64898/), or a journal article's DOI, which resolves to the preprint it was posted as (10.1016/j.cell.2020.01.001 → 10.1101/614172); 10.64898/ DOIs resolve through the preprint's own journal DOI
  • Returns the preprint DOI, journal DOI, journal name, published date, corresponding-author institution, and the server that answered; if no server answers it raises a retryable upstream_unavailable or rate_limited, never doi_not_found
  • Cold Spring Harbor Laboratory Press journal DOIs (10.1101/gr.…, gad.…, lm.…) share the preprint prefix and cannot be resolved by DOI

biorxiv_list_published_versions tool

  • Takes a start_date/end_date interval of journal publication dates and server (default both); each row matches the record biorxiv_get_published_version returns, and may be a preprint posted years earlier
  • Returns limit rows per server (default 25, up to the API's 100-row page) from an integer cursor, continued at each server's nextCursor; a cursor past the last row is marked exhausted: true, and a server that did not answer is named in failed[]
  • Optional publisher, a journal DOI prefix (10.7554 for eLife), lists only the bioRxiv preprints published under it; server: "both" queries bioRxiv alone, and server: "medrxiv" or a prefix the API does not recognize raises invalid_publisher. These rows carry no journal name, authors, or abstract
  • Abstracts are omitted by default; include_abstract: true adds them

biorxiv_get_fulltext tool

  • Takes a DOI, server (default both), and an optional version (or a vN suffix; the two must agree, and a version the preprint lacks raises version_not_found); returns Markdown extracted from the rendered HTML article page, naming the answering server
  • Table cells are not on the page: each table keeps its caption, and omittedTables names it with the URL that serves its cells
  • Pages via offset/limit characters (default 20,000), reporting totalChars, remainingChars, hasMore, and wordCount; PDF-only preprints and blocked pages raise fulltext_unavailable, routing to biorxiv_get_preprint

biorxiv_list_categories tool

  • No API call — a static list of 25 bioRxiv and 51 medRxiv categories, limited to the ones the listing API filters on
  • Use it to pick a category for biorxiv_list_recent

Features

Built on @cyanheads/mcp-ts-core: stdio and Streamable HTTP transports, pluggable auth (none / jwt / oauth), swappable storage (in-memory, filesystem, Supabase, Cloudflare KV/R2/D1), structured logging with optional OpenTelemetry tracing.

bioRxiv-specific:

  • BiorxivApiService wraps api.biorxiv.org (details, publications, and crosswalk endpoints) and EuropePmcService wraps EuropePMC search, both with retry and exponential backoff
  • BiorxivFullTextService extracts Markdown from the article pages on www.biorxiv.org / www.medrxiv.org
  • Every upstream retry ladder runs on what is left of the tool call's one 50 s budget, so a hung origin ends before a client's 60 s request timeout — in a classified, retryable error, or, when the step that hung is optional, in a result that says what is missing
  • Queries biorxiv and medrxiv in parallel when server="both", each result naming the server that answered; a lookup by DOI stops waiting once the server holding that DOI answers
  • Polite User-Agent header including a mailto address (BIORXIV_MAILTO env var) per Cold Spring Harbor Lab API guidelines
  • Pairs with pubmed-mcp-server (post-publication), openalex-mcp-server (citation analytics), and crossref-mcp-server (DOI metadata)

Agent-friendly output:

  • Graceful partial failure — per-DOI and per-server failures land in failed[] with a typed reason and retryable flag instead of aborting the call
  • Rate-limit transparency — a 429 surfaces as reason: "rate_limited" with the parsed retryAfter wait, distinct from upstream_unavailable
  • Typed enrichment status — biorxiv_search_preprints results carry enriched plus a typed enrichment_error (service_error / rate_limited / not_found)
  • Clean titles and abstracts — export markup and symbol placeholders ({beta}, [≥]) are resolved to plain text

Getting started

Connect to the hosted instance, no install:

claude mcp add --transport http biorxiv-mcp-server https://biorxiv.caseyjhand.com/mcp

Or run it locally:

claude mcp add biorxiv-mcp-server -- npx -y @cyanheads/biorxiv-mcp-server

For other clients, add this to the MCP config file:

{
  "mcpServers": {
    "biorxiv-mcp-server": {
      "command": "npx",
      "args": ["-y", "@cyanheads/biorxiv-mcp-server"]
    }
  }
}

A contact email in BIORXIV_MAILTO (-e [email protected], or an env entry) identifies your requests in the User-Agent header, as the Cold Spring Harbor Lab API guidelines ask. For Docker or a source build, see Running the server.

Configuration

All configuration is validated at startup via Zod schemas in src/config/server-config.ts.

VariableDescriptionDefault
BIORXIV_MAILTOEmail address for the User-Agent header; optional but recommended.—
BIORXIV_API_BASE_URLOverride the bioRxiv API base URL.https://api.biorxiv.org
EUROPEPMC_API_BASE_URLOverride the EuropePMC base URL.https://www.ebi.ac.uk/europepmc/webservices/rest
BIORXIV_WEB_BASE_URLOverride the bioRxiv website base URL (full-text HTML source for biorxiv_get_fulltext).https://www.biorxiv.org
MEDRXIV_WEB_BASE_URLOverride the medRxiv website base URL (full-text HTML source for biorxiv_get_fulltext).https://www.medrxiv.org
MCP_TRANSPORT_TYPETransport: stdio or http.stdio
MCP_HTTP_PORTHTTP server port.3010
MCP_HTTP_ENDPOINT_PATHHTTP endpoint path./mcp
MCP_AUTH_MODEAuth mode: none, jwt, or oauth.none
MCP_LOG_LEVELLog level (debug, info, warning, error, etc.).info
LOGS_DIRDirectory for log files (Node.js only).<project-root>/logs
LOG_TOOL_FAILURE_PAYLOADSLog each failed tool call's arguments and result, redacted by key name and capped at LOG_TOOL_FAILURE_PAYLOAD_MAX_BYTES (default 16384). A secret inside a free-form value is not redacted.false
OTEL_ENABLEDEnable OpenTelemetry instrumentation.false

See .env.example for the full list of optional overrides.

Running the server

Local development

Requires Bun v1.4.0 or higher (or Node.js v24+).

  • Clone and install:

    git clone https://github.com/cyanheads/biorxiv-mcp-server.git
    cd biorxiv-mcp-server && bun install
    cp .env.example .env   # optionally set BIORXIV_MAILTO
    
  • Build and run:

    # One-time build
    bun run rebuild
    
    # Run the built server
    bun run start:stdio
    # or
    bun run start:http
    
  • Run checks and tests:

    bun run devcheck   # Lint, format, typecheck, security
    bun run test       # Vitest test suite
    bun run lint:mcp   # Validate MCP definitions against spec
    

Docker

docker run --rm -e [email protected] -p 3010:3010 ghcr.io/cyanheads/biorxiv-mcp-server:latest

The image defaults to HTTP transport, stateless session mode, and logs to /var/log/biorxiv-mcp-server; the server listens at http://localhost:3010/mcp. To run it over stdio from an MCP client, use "command": "docker" with "args": ["run", "-i", "--rm", "-e", "MCP_TRANSPORT_TYPE=stdio", "ghcr.io/cyanheads/biorxiv-mcp-server:latest"]. To build locally, docker build -t biorxiv-mcp-server .; OpenTelemetry peer dependencies are installed by default — build with --build-arg OTEL_ENABLED=false to omit them.

Project structure

DirectoryPurpose
src/index.tscreateApp() entry point — registers tools and initializes services.
src/configServer-specific environment variable parsing and validation with Zod.
src/mcp-server/toolsTool definitions (*.tool.ts). Seven tools across bioRxiv and medRxiv.
src/services/biorxivBiorxivApiService — details, publications, and crosswalk endpoint wrappers with retry.
src/services/biorxiv-fulltextBiorxivFullTextService — rendered HTML article page fetch and Markdown extraction.
src/services/europe-pmcEuropePmcService — preprint keyword/author search endpoint wrapper.
tests/Unit and integration tests mirroring the src/ structure.

Development guide

See CLAUDE.md for development guidelines and architectural rules. The short version:

  • Handlers throw, framework catches — no try/catch in tool logic
  • Use ctx.log for request-scoped logging, ctx.state for tenant-scoped storage
  • Register new tools via the barrel in src/mcp-server/tools/definitions/index.ts
  • Wrap external API calls: validate raw → normalize to domain type → return output schema; never fabricate missing fields

Contributing

Issues are welcome. Run checks and tests before submitting:

bun run devcheck
bun run test

License

Apache-2.0 — see LICENSE for details.

版本与发布记录

@cyanheads/biorxiv-mcp-server 共发布 31 个版本,首次发布于 2026/05/23;过去 12 个月发布了 31 个版本。

版本发布日期距今
0.5.1latest2026/10/3012 天前
0.5.02026/10/2813 天前
0.4.32026/10/2517 天前
0.4.22026/10/2418 天前
0.4.12026/10/1824 天前
0.4.02026/10/1526 天前

关于 @cyanheads/biorxiv-mcp-server 的常见问题

@cyanheads/biorxiv-mcp-server 是什么?

Search and retrieve bioRxiv and medRxiv preprints — by DOI, date interval, or keyword — via MCP. STDIO or Streamable HTTP.

如何安装 @cyanheads/biorxiv-mcp-server?

在项目目录运行 npm install @cyanheads/biorxiv-mcp-server,或使用 pnpm add / yarn add / bun add。它还提供命令行工具 biorxiv-mcp-server,可以用 npx biorxiv-mcp-server 直接运行。

@cyanheads/biorxiv-mcp-server 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@cyanheads/biorxiv-mcp-server 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@cyanheads/biorxiv-mcp-server 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js >=24.0.0。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@cyanheads/biorxiv-mcp-server 可以商用吗?

@cyanheads/biorxiv-mcp-server 使用 Apache-2.0 许可。宽松许可:允许商业使用、修改和再分发,并附带明确的专利授权;分发时需保留许可与 NOTICE 文件,修改过的文件要注明改动。以上为概括,不构成法律意见,请以许可原文为准。

@cyanheads/biorxiv-mcp-server 的下载量有多少?

根据 npm 官方下载统计,@cyanheads/biorxiv-mcp-server 在 2026/10/11 – 2026/11/09 这 30 天内被下载 2,481 次,日均约 83 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@cyanheads/biorxiv-mcp-server 还在维护吗?

最新版本 0.5.1 发布于 2026/10/30(12 天前);至今共发布 31 个版本,其中过去 12 个月发布了 31 个;首次发布于 2026/05/23。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。