跳到主要内容

MCP Server

Overview

MCP (Model Context Protocol) Server is an embedded protocol service that exposes your Zotero library and Synthesis capabilities as 40+ MCP tools. MCP-compatible clients (Claude Desktop, Cursor, VS Code extensions, etc.) can directly access Zotero data.

MCP Server shares the underlying Host Bridge capability registry but follows the MCP protocol specification (Streamable HTTP transport, JSON-RPC 2.0).

Configuration

Zotero → Settings → Zotero Agents → Host Bridge → Enable MCP Server

A single checkbox toggles the server on/off. Enabled by default.

Non-configurable Defaults

SettingValueReason
Listen address127.0.0.1Security: loopback only
Origin validationStrictOnly 127.0.0.1, localhost, [::1]
Request size limit1 MBMemory protection
Write protectionEnabledAll write operations require approval

Security

  • Bearer Token auth: shares the same session/master token as Host Bridge
  • Loopback only: no remote access possible
  • Origin validation: cross-origin requests rejected (403)
  • 1 MB cap: oversized bodies rejected at 413
  • Single-threaded queue: 1 running + 8 pending, 45s run timeout, 30s queue timeout
  • Circuit breakers: 3 failures in 5 minutes → tool paused for 60s

Connecting MCP Clients

Endpoint

http://127.0.0.1:<port>/mcp

Port is auto-assigned (range 26370-26569). Check the Host Bridge endpoint in preferences for the actual port.

Claude Desktop Configuration Example

{
"mcpServers": {
"zotero-skills": {
"type": "http",
"url": "http://127.0.0.1:26370/mcp",
"headers": {
"Authorization": "Bearer <your-token>"
}
}
}
}

Get the token from Preferences → Host Bridge → Copy Master Token.

Protocol Details

  • Transport: Streamable HTTP (POST /mcp)
  • Version: 2025-06-18
  • Server identity: zotero-skills / "Zotero Agents Context Broker" v0.4.0
  • GET /mcp → 405 (only POST accepted)
  • Requests without id → treated as notifications (no response)
  • id: null → explicitly invalid

Tool Inventory

All 40+ tools

Read Tools

ToolDescription
get_current_viewCurrent Zotero view info
get_selected_itemsCurrently selected item summaries
search_itemsSearch items (limit ≤ 50)
list_library_itemsPaginated item listing
get_item_detailFull item metadata
get_item_notesList child notes
get_note_detailRead note body (chunked, ≤16k chars per chunk)
list_note_payloadsList workflow payloads in a note
get_note_payloadRead one payload
get_item_attachmentsList attachment manifests (no file bytes)
prepare_paper_reading_contextAggregate metadata, notes, payloads, attachments for one paper

Write Tools (require approval)

ToolDescription
preview_mutationPreview a write operation without executing
update_item_fieldsUpdate allowed fields on one item
add_item_tagsAdd tags to one or more items
remove_item_tagsRemove tags
create_child_noteCreate a child note
update_noteUpdate a note body
create_markdown_noteCreate a note with rendered HTML + base64 markdown payload
update_markdown_noteUpdate an existing markdown-backed note
ingest_paperIngest a paper by DOI/arXiv/PMID/ISBN (with PDF attachment)
add_items_to_collectionAdd items to a collection
remove_items_from_collectionRemove items from a collection

Diagnostic Tool

ToolDescription
get_mcp_statusService diagnostics: queue, circuit breakers, recent requests

Synthesis Tools

ToolDescription
topics.listList all topics
topics.find_by_paper_refFind topics by paper reference
topics.get_contextGet full topic context
topics.get_review_inputAssemble topic review package
schemas.getGet schema definitions
concepts.queryQuery the concept knowledge base
citation_graph.query_clusterQuery citation cluster
citation_graph.get_overviewGet graph overview
citation_graph.get_sliceExtract subgraph slice
citation_graph.get_metricsCompute graph metrics (pagerank, foundation, frontier)
citation_graph.rank_external_referencesRank external references
citation_graph.rank_library_papersRank library papers
library_index.getPaginated library index
resolvers.resolveResolve reference/topic resolvers
reference_index.getGet reference index
paper_artifacts.get_manifestGet artifact manifest
paper_artifacts.readRead artifact content
paper_artifacts.export_filteredExport filtered artifacts
paper_artifacts.resolve_topic_digestResolve topic digest
insights.get_attention_queueGet attention queue

Write Protection

Write tools follow the same approval model as Host Bridge:

MCP client invokes write tool

├── Bearer Token validated
├── Tool scope extracted
├── Approval check:
│ ├── Read-only tool → execute immediately
│ ├── Pre-approved write → execute immediately
│ └── Approval needed → queue to Zotero UI
└── Execute / Deny

Queue: max 50 pending approvals; >10 denied writes in 5 minutes → circuit breaker (disabled for 30s).

Next Steps