
Zh Education Mcp
io.github.malkreide由 GitHub 账号 malkreide 发布v0.3.0更新于 Oct 25, 2026
Canton and City of Zurich education data: schools, statistics, infrastructure
概览
只读 MCP 服务器,让助手访问苏黎世州与苏黎世市教育统计数据(BISTA):学生人数、学区趋势、国籍构成与高中毕业率。
- 可以做什么
- 列出苏黎世州的学校社区与学区(Schulkreis),并查询有效名称
- 运行要求
- 需要 Python 3.11+ 及 uv 或 pip,也可用 uvx 免安装运行。需联网访问 BISTA 公共 API;无需 API 密钥或账号。
安装
在 SourceWeft 中
- 打开 控制台中的 Zh Education Mcp,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
🇨🇭 Part of the Swiss Public Data MCP Portfolio
📊 zh-education-mcp
[Version] [License: MIT] [Python 3.11+] [MCP] [No Auth Required] [CI]
MCP server for education statistics of the Canton and City of Zurich (BISTA)
Overview
zh-education-mcp connects AI assistants to the Bildungsstatistik Kanton Zürich (BISTA) — the official education statistics of the Canton of Zurich. It provides structured access to pupil numbers, school district trends, secondary school profiles, nationality breakdowns, and gymnasium graduation rates.
All data is fetched from the BISTA public API (bista.zh.ch/basicapi/ogd/) — no API key required. Data is updated annually on 15 September (reference date).
Anchor demo query: "How has the number of pupils in school district Letzi developed over the last 5 years?"
Demo
[zh-education-mcp demo: Claude queries BISTA data]
Features
- 📊 8 tools for education data across all school levels
- 🔍 School district trends — pupil numbers for all Schulkreise (Letzi, Glattal, Schwamendingen, Oerlikon, Uto, Waidberg, Zürichberg) from 2000 to present
- 🏫 Secondary school profiles — breakdown by requirement type (Sek A/B/C, Mittelschule, special classes)
- 🌐 Nationality structure — top nationalities of pupils per school community
- 🎓 Gymnasium graduation rates — Maturitätsquote by municipality, district, and canton
- 📈 Canton-wide overview — all learners by school level, type, gender, and nationality
- 🏠 Residence-based trends — pupil counts by place of residence (Bezirk / Gemeinde)
- 🏛️ Mittelschulen — Gymnasium, FMS, HMS statistics
- 🔓 No API key required — all data under CC BY 4.0
- ☁️ Dual transport — stdio (Claude Desktop) + Streamable HTTP (cloud)
Prerequisites
- Python 3.11+
- uv (recommended) or pip
Installation
Or with uvx (no permanent installation):
Quickstart
Try it immediately in Claude Desktop:
"Wie hat sich die Lernendenzahl im Schulkreis Letzi entwickelt?" "Zeige die Maturitätsquote der Stadt Zürich" "Welche Nationalitäten sind in Adliswil am häufigsten?"
→ More use cases by audience →
Configuration
Claude Desktop
Edit ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
Or with uvx:
Config file locations:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
Cloud Deployment (Streamable HTTP for browser access)
For use via claude.ai in the browser (e.g. on managed workstations without local software):
Render.com (recommended):
- Push/fork the repository to GitHub
- On render.com: New Web Service → runtime Docker (uses the provided
Dockerfile) - Set env vars:
MCP_TRANSPORT=streamable-http,MCP_HOST=0.0.0.0,MCP_PORT=8000, andMCP_CORS_ORIGINS=https://claude.ai - In claude.ai under Settings → MCP Servers, add:
https://your-app.onrender.com/mcp
💡 "stdio for the developer laptop, Streamable HTTP for the browser."
Health probe: GET /health. Full deployment guide (container, load balancing, CORS,
resource limits): docs/deployment.md.
Available Tools
Example Use Cases
Architecture
Data Source Characteristics
Project Structure
Known Limitations
- Annual updates only: BISTA data is updated once per year (reference date: 15 September). The 24h in-memory cache matches this cycle.
- CSV-based API: The BISTA API returns CSV data; large datasets may take a moment to parse.
- School community names: Names must match exactly (use
zh_edu_list_schulgemeindento find valid names).
Safety & Limits
Testing
The live suite also runs on a schedule: every Monday 05:23 UTC, plus on
demand (live-tests.yml). A red run opens
an upstream-labelled issue; a green one closes it. -m "not live" is not a
place where tests run, and these three are the only tests here that can
contradict a wrong assumption about BISTA — see
CONTRIBUTING.
MCP Protocol Version
This server speaks two protocol eras over the same endpoint. The client's first request on a connection decides which one applies; a later claim from the other era is refused.
Both revisions are pinned in
tests/test_protocol_version.py and asserted
against the installed SDK, so a Dependabot bump of mcp cannot move either one
silently. The handshake ceiling is measured against a live initialize through
the assembled ASGI stack, not read off a constant name.
Note that the SDK's LATEST_PROTOCOL_VERSION is an alias for the modern
era, not for the handshake era — pinning against it alone would leave the era
that current clients actually negotiate free to drift.
What the server itself contributes on the modern era
Speaking the revision is the SDK's job. What a server has to supply is listed
here, and measured in
tests/test_modern_protocol.py against real
requests through the assembled ASGI stack rather than against constants:
The identity is not maintained in src/: version, description and website
come from the distribution metadata and therefore from pyproject.toml — the
one source check_version_sync.py permits.
Before this revision the server stamped version: "" onto every modern-era
result.
Update policy. When the gate fails, do not edit the constant blindly: read
the spec changelog between the two revisions, verify the server still behaves,
then move the constant, this section, README.de.md and
CHANGELOG.md together.
Project phase: Phase 1 — read-only (all tools readOnlyHint: true). See
docs/roadmap.md.
Release
Publishing is driven by a GitHub release (release: published →
publish.yml): build → gate → PyPI → MCP Registry.
The gate (check_release_artifacts.py) runs
before the upload and inspects the built wheel, not the sources:
- exactly one
mcp-name:marker (an HTML comment, see the bottom of this file) in the wheel METADATA — the MCP Registry proves PyPI ownership with it — and it must matchserver.jsonname server.jsondescriptionat most 100 characters; the Registry answers422, and only after the PyPI upload has already succeededserver.jsonversion equal topyproject.tomlversion, and the git tag equal to the version actually built
It sits ahead of the upload because nothing is correctable behind it: a PyPI version is immutable, so a fix costs a version bump.
If you edit this README: the marker at the very bottom is shipped as part of
the package description (readme = "README.md" in pyproject.toml), and removing
it fails the gate. README.de.md carries no marker and is not published. The
version badge above is checked on every pull request by
check_version_sync.py against pyproject.toml
and server.json.
Changelog
See CHANGELOG.md
Contributing
See CONTRIBUTING.md · 🇩🇪 Beitragen
Security
See SECURITY.md · 🇩🇪 Sicherheit
License
MIT License — see LICENSE
Author
Hayal Oezkan · malkreide
Credits & Related Projects
- BISTA: pub.bista.zh.ch — Bildungsstatistik Kanton Zürich (CC BY 4.0)
- Protocol: Model Context Protocol — Anthropic / Linux Foundation
- Related: zurich-opendata-mcp — Zurich city open data (parking, weather, parliament)
- Related: swiss-cultural-heritage-mcp — Swiss cultural heritage data
- Related: fedlex-mcp — Swiss federal law
- Portfolio: Swiss Public Data MCP Portfolio
Installation
Run via uv's uvx — no clone or manual install needed. Add to your MCP client config (mcpServers for Claude Desktop, Cursor and Windsurf; use a top-level servers key for VS Code in .vscode/mcp.json):
来源:README.md,提交 5651efa
工具
0版本历史
2- v0.3.0最新Sep 19, 2026
- v0.2.7Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分