swiss-academic-libraries-mcp

swiss-academic-libraries-mcp

Enables AI models to search and retrieve bibliographic and digitized records from Swiss academic libraries (swisscovery, e-rara, e-periodica, e-manuscripta) via open protocols without requiring API keys.

Category
访问服务器

README

🇨🇭 Part of the Swiss Public Data MCP Portfolio

📚 swiss-academic-libraries-mcp

PyPI version License: MIT Python 3.11+ MCP No Auth Required CI

MCP server providing access to Swiss academic libraries — swisscovery, e-rara, e-periodica, e-manuscripta. No API key required.

🇩🇪 Deutsche Version

Demo

Demo: Claude using swisscovery_search and erara_list_records


Overview

swiss-academic-libraries-mcp connects AI models to the full Swiss academic library infrastructure via standardised, open protocols. It covers the swisscovery union catalogue (500+ libraries, 10M+ records) and three digitalisation platforms: historical prints (e-rara), periodicals (e-periodica) and manuscripts (e-manuscripta).

All data sources use open, authentication-free protocols (SRU/MARC21, OAI-PMH/Dublin Core). The server supports both local use via Claude Desktop (stdio transport) and cloud deployment (Streamable HTTP).

Anchor demo query: "Which Swiss university dissertations on primary school pedagogy are held in Swiss libraries, and are any of them digitised in e-rara?"


Features

  • 11 tools across 4 data sources — all read-only, no API key required
  • swisscovery search with full CQL syntax: full-text, title, author, subject, ISBN/ISSN
  • OAI-PMH harvesting with date range and collection filters plus pagination via resumption tokens
  • MARC21 parser extracting 20+ fields (title, creator, publication info, subjects, abstract, URLs)
  • Dublin Core parser for all three digitalisation portals
  • Dual transport: stdio for Claude Desktop · Streamable HTTP for cloud/self-hosted deployments
  • 2 built-in prompts: research-workflow and education-research
  • Markdown and JSON output for all tools
  • 34 unit tests (no network) + 6 live smoke tests

Data Sources

Source Protocol Content Records
swisscovery (SLSP) SRU / MARC21 500+ Swiss libraries 10M+
e-rara OAI-PMH / Dublin Core Digitised historical prints 250k+
e-periodica OAI-PMH / Dublin Core Digitised periodicals (1750–today) 1M+ articles
e-manuscripta OAI-PMH / Dublin Core Manuscripts & archival material 100k+

Tools

Tool Source Function
library_info Entry point: overview of all sources and tools
swisscovery_search swisscovery Full-text / CQL search across the union catalogue
swisscovery_get_record swisscovery Single record by MMS-ID
erara_list_records e-rara Prints filtered by date / collection
erara_get_record e-rara Single item by OAI identifier
erara_list_collections e-rara All participating libraries
eperiodica_list_records e-periodica Articles filtered by date
eperiodica_get_record e-periodica Single article by OAI identifier
emanuscripta_list_records e-manuscripta Manuscripts filtered by date / collection
emanuscripta_get_record e-manuscripta Single object by OAI identifier
emanuscripta_list_collections e-manuscripta All archives / collections

Example Use Cases

Query Tool
"Which books about Swiss primary schools are held in Swiss libraries?" swisscovery_search
"Show digitised historical works from ETH Library" erara_list_records
"Which Swiss periodicals were digitised in 2023?" eperiodica_list_records
"What manuscript collections does e-manuscripta hold?" emanuscripta_list_collections

Prerequisites

  • Python 3.11 or higher
  • uv / uvx (recommended) or pip
  • Internet access (all APIs are publicly available)

Installation

Claude Desktop (recommended)

Add to claude_desktop_config.json:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json

{
  "mcpServers": {
    "swiss-academic-libraries": {
      "command": "uvx",
      "args": ["swiss-academic-libraries-mcp"]
    }
  }
}

Restart Claude Desktop — the server starts automatically on first use.

Cloud / Self-hosted (Streamable HTTP)

uvx swiss-academic-libraries-mcp --http --port 8000 [--host 127.0.0.1]

Security & Deployment Notes

  • Default binding is 127.0.0.1 (loopback only). The server has no built-in authentication.
  • Use --host 0.0.0.0 only when running behind a reverse proxy that provides authentication and per-IP rate limits (e.g. nginx with limit_req + OAuth2-Proxy). Non-loopback bindings emit a WARN log.
  • Logs go to stderr; set verbosity with MCP_LOG_LEVEL=DEBUG|INFO|WARNING.

Development

git clone https://github.com/malkreide/swiss-academic-libraries-mcp
cd swiss-academic-libraries-mcp
pip install -e .

Quickstart

Start by calling library_info for a full overview. Then:

"Which books about Swiss primary schools are held in Swiss libraries?"
→ swisscovery_search(query='subject = "Volksschule"', max_records=20)

"Show digitised historical works from ETH Library"
→ erara_list_records(set_spec="zut")

"Which Swiss periodicals were digitised in 2023?"
→ eperiodica_list_records(from_date="2023-01-01", until_date="2023-12-31")

"What manuscript collections does e-manuscripta hold?"
→ emanuscripta_list_collections()

→ [More use cases by audience](EXAMPLES.md) →

💡 "No API key — just install and query."

CQL Search Syntax (swisscovery)

Full text:     Volksschule Zürich
Title:         title = "education reform"
Author:        creator = "Pestalozzi"
Subject:       subject = "pedagogy"
ISBN:          isbn = "978-3-05-006234-0"
Combined:      title = "school" AND creator = "Pestalozzi"
Pagination:    start_record = 11

Configuration

No API keys or environment variables required.

Parameter Default Description
--http off Enable Streamable HTTP transport
--port 8000 Port for HTTP transport

Project Structure

swiss-academic-libraries-mcp/
├── src/
│   └── swiss_academic_libraries_mcp/
│       ├── __init__.py       # Package init
│       ├── server.py         # FastMCP server, 11 tools, 2 prompts, 1 resource
│       └── api_client.py     # HTTP client, MARC21 + OAI-PMH/DC parsers
├── tests/
│   └── test_server.py        # 34 unit tests + 6 live smoke tests
├── pyproject.toml
├── CHANGELOG.md
├── CONTRIBUTING.md
├── LICENSE
├── README.md                 # This file (English)
└── README.de.md              # German version

Testing

# Unit tests (no network required)
PYTHONPATH=src pytest tests/ -m "not live"

# Live smoke tests (internet required)
PYTHONPATH=src pytest tests/ -m "live"

Safety & Limits

  • Read-only: All tools perform HTTP GET requests against public SRU and OAI-PMH endpoints — no data is written, modified, or deleted.
  • No personal data: The APIs return bibliographic metadata (titles, authors, publication info, subject headings) and public digitisation records. No personally identifiable information (PII) about library users is processed or stored.
  • Rate limits: swisscovery SRU and the OAI-PMH endpoints are public and have no documented hard limits, but OAI-PMH harvesting is paginated via resumption tokens — use from_date / until_date and keep max_records reasonable. The server enforces a 30s timeout per request.
  • Data freshness: Results reflect the upstream catalogues at query time. No caching is performed by this server; indexing latency is controlled by SLSP and the digitisation platforms.
  • Terms of service: Data is subject to the ToS and licences of each source — swisscovery / SLSP, e-rara, e-periodica, e-manuscripta. Most digitised material is in the public domain or under Creative Commons licences; always check the rights statement on the individual record before redistribution.
  • No guarantees: This is a community project, not affiliated with SLSP, ETH Library, or any of the participating institutions. Availability depends on the upstream APIs.

Contributing

Contributions are welcome! Please read CONTRIBUTING.md for guidelines on:

  • Reporting bugs and requesting features
  • Setting up the development environment
  • Code style and test requirements
  • Submitting pull requests

This project follows the conventions of the Swiss Public Data MCP Portfolio.


Changelog

See CHANGELOG.md


Deployment for Swiss Public Administration

If you self-host this server for a Swiss school authority, archive, or municipal use case:

  • Data residency: prefer on-premise or a CH-based cloud provider. The query patterns themselves (which library searches a civil servant runs) may reveal ongoing research and are best kept on Swiss infrastructure.
  • Upstream calls go exclusively to CH-hosted services: SLSP / swisscovery, ETH-Bibliothek (e-rara, e-periodica, e-manuscripta). No data leaves Switzerland.
  • Logging: logs are written to stderr; configure your IT retention policy accordingly (e.g. systemd-journal MaxRetentionSec).
  • HTTP transport must run behind a reverse proxy with authentication and per-IP rate limits (see Security & Deployment Notes above).

License

MIT License — see LICENSE


Author

Hayal Oezkan · github.com/malkreide


Credits & Related Projects

Server Description
zurich-opendata-mcp City of Zurich Open Data
eth-library-mcp ETH Library Discovery & Persons API
swiss-statistics-mcp Swiss Federal Statistics (BFS)
fedlex-mcp Swiss Federal Law via Fedlex SPARQL
swiss-transport-mcp OJP journey planning, SIRI-SX disruptions

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选