ILO Statistics (ILOSTAT) MCP Server
ILO 劳动统计 (ILOSTAT) — MCP 服务器
一个公开、托管、以来源追溯为先的 MCP 服务器,用于国际劳工组织 (ILO) 统计——即 ILOSTAT 数据库——无需安装、无需账户、无需 API 密钥。将您的 MCP 客户端指向托管端点,即可按国家、年份、性别和年龄查询失业、就业、工资、工作时间及其他劳动指标。它运行在 Cloudflare Workers 上,基于 Streamable HTTP,并与官方 ILOSTAT SDMX REST API 通信。
每个响应都带有来源追溯块(源 URL、数据版本、真实检索时间戳、许可证、ILO 引用)——精确的数字附带审计轨迹,而非从训练数据中猜测的数字。
使用(托管——无需设置)
将任何 MCP 客户端指向 Streamable HTTP 端点:
https://ilo.sidneybissoli.com/mcpClaude Desktop / Claude Code 及其他支持原生远程的客户端:
{
"mcpServers": {
"ilostat": {
"url": "https://ilo.sidneybissoli.com/mcp"
}
}
}对于以命令方式启动 MCP 服务器的客户端,请使用 mcp-remote 桥接:
{
"mcpServers": {
"ilostat": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://ilo.sidneybissoli.com/mcp"]
}
}
}ilo-mcp-server.sidneybissoli.workers.dev 主机名也可作为备用使用。
Related MCP server: world-bank-economic-mcp
本地运行(stdio)
不想通过第三方主机路由查询?同一个服务器也可以作为本地 stdio 进程运行,直接与官方 ILOSTAT API 通信——相同的 4 个工具、资源和提示,相同的限制,相同的来源追溯块,无需 Cloudflare 介入。
无需安装——该包位于 npm(ilo-mcp-server,Node ≥ 20):
{
"mcpServers": {
"ilostat": {
"command": "npx",
"args": ["-y", "ilo-mcp-server"]
}
}
}或从源码运行:
git clone https://github.com/SidneyBissoli/ilo-mcp-server
cd ilo-mcp-server
npm install
npm run build
node dist/cli.js # serves MCP over stdio (Ctrl+C to stop)(然后将客户端指向 node /path/to/ilo-mcp-server/dist/cli.js)。
与托管服务器的差异,均因缺少 Cloudflare 绑定所致:SDMX 缓存位于进程内存中(结构和代码表在会话内复用,而非跨会话);搜索目录在首次搜索时从官方端点下载(其真实的 retrieved_at 在来源追溯中报告);无使用指标、速率限制或认证。日志输出到 stderr——stdout 仅承载 JSON-RPC 流。仓库中的 Dockerfile 构建此运行时(供 Glama 注册表使用)。
工具
工具 | 功能 | 来源 |
| 对约 1,210 个数据流进行关键词搜索(按 | 本地目录(无上游调用) |
| 数据流的维度、代码表、版本和默认选择 | 缓存结构(未命中 → 上游) |
| 某个维度的有效代码(按 | 缓存代码表(未命中 → 上游) |
| 按维度和时期筛选的观测值 | 每次查询 1 次实时 REST 调用 |
典型流程:ilo_search_indicators → ilo_get_indicator_metadata / ilo_list_dimension_values 以发现有效的筛选代码 → ilo_get_data 并附带国家和时期筛选。
每个响应都带有来源追溯块 v1.0(@sbissoli/mcp-provenance,通过 provenance_mode 参数支持 concise/detailed 模式),通过三个渠道呈现:structuredContent、命名空间 _meta(com.sidneybissoli.ilostat/*)以及文本页脚。
资源和提示
三个资源(静态,text/markdown,无上游调用),客户端可在调用工具前将其附加到上下文中——它们可节省大多数会话在“哪个数据流、哪些代码”上花费的 2–3 次发现调用:
URI | 内容 |
| 工具工作流、稳定代码约定( |
| 按主题验证的数据流 ID(失业、就业、参与率、工资、工时、非正规就业、NEET、SDG 8、生产率) |
| 每个来源追溯字段的含义以及如何引用 ILO |
三个提示——现成的工作流,串联工具并以引用规则结束(参数为字符串;时期参数可选):
提示 | 参数 | 结果 |
|
| 单个国家的劳动力市场概况(失业、参与率、就业率、非正规就业、NEET、收入、工时) |
|
| 跨国家/聚合的比较表,单次数据调用,标记模型估计值与报告数据 |
|
| 单个指标的时间序列,含首/末值、峰值/谷值及 |
资源和提示中引用的每个数据流 ID 都经过测试套件与目录种子核对,因此文档不会指向搜索无法找到的 ID。
行为和限制
ilo_get_data中必须提供REF_AREA,每次调用最多 30 个地区。 ILO 网关在无限制查询时会超时(HTTP 504),因此服务器从不发出此类查询;对于宽面板,请将地区分批和/或按时期分页(start_period/end_period)。错误消息会说明具体做法。每个数据查询仅一次实时 REST 调用。 数据从不缓存——每次
ilo_get_data结果都在请求时从 ILOSTAT 获取。数据流结构(TTL 24 小时)和代码表(TTL 7 天,跨数据流共享)会被缓存。data_vintage是数据流的上次更新日期,由 ILO 发布(LAST_UPDATE注释,规范化为 ISO 格式)。retrieved_at始终是从 ILOSTAT 提取的真实时刻,与任何缓存值一同保留——绝不是构建或响应时间。缓存响应会说明(served_from_cache: true)。指标目录是本地快照(约 1,210 个数据流),定期刷新;其自身的
retrieved_at在ilo_search_indicators的来源追溯中报告,因此其时效始终可见。每次上游调用都带有可识别的 User-Agent(服务 URL + 联系方式),以便 ILO 管理员联系运营方。
语言:英语;时区:UTC(ILO 数据以英语发布)。
来源追溯字段
derived— 仅对真实转换(聚合、服务器计算的比率、插值、协调)为true,且始终带有derivation_note;单位转换和舍入不计入。此服务器不转换数值,因此derived始终为false。notices— 逐字重现OBS_STATUS的值(SDMX 状态/免责声明渠道,例如“序列中断”),并附计数。技术性的逐观测属性(DECIMALS等)保留在行上(rows[].attributes)。
数据许可和署名
ILOSTAT 数据和元数据:CC BY 4.0(自 2023-05-03 起;许可证于 2026-08-04 验证)。
每个响应中都包含 ILO 署名(
citation字段):International Labour Organization, ILOSTAT, https://ilostat.ilo.org/data/, accessed <date>.不使用 ILO 标志。本服务未经 ILO 认可。
自托管 / 开发
以下所有内容仅用于运行您自己的实例——使用公共服务器不需要这些。
npm install
npm run typecheck && npm test # 96 offline tests (parsers, key, tools, output contract, resources/prompts, in-memory catalogue, eval fixtures)
npm run dev # http://localhost:8787/mcp (Worker)
npm run build && npm start # stdio runtime (dist/cli.js)
# Catalogue seed (D1) — required before first use:
node scripts/seed-catalog.mjs # downloads via curl and generates scripts/seed-catalog.sql
npx wrangler d1 execute ilostat-catalog --local --file=scripts/seed-catalog.sql
npx wrangler d1 execute ilostat-catalog --remote --file=scripts/seed-catalog.sql
npm run deploy
node scripts/smoke-mcp.mjs # smoke test against production (initialize → 4 tools → errors)
npm run manifest:lhm # regenerate tools/resources/prompts in lhm.plugin.json from the real server
# (the seed also writes tests/fixtures/catalog-ids.txt — the versioned id list the tests check resources/prompts against)绑定(参见 wrangler.jsonc):KV SDMX_CACHE、D1 CATALOG_DB、Durable Object USAGE(基于 SQLite 的使用计数器)、CF_VERSION_METADATA。可选 Bearer 认证(wrangler secret put API_KEY);按 IP 的令牌桶速率限制。
运营方注意事项:
ILOSTAT 仅在通过
Accept头协商时返回 JSON(application/vnd.sdmx.{structure,data}+json);?format=被忽略并返回 XML。ILO 网关对 Node 的
fetch(undici)默认发送的Accept-Language: *头返回 HTTP 500(languageTag1);因此每次上游调用都显式设置Accept-Language: en(Cloudflare 运行时不会发送此类头,因此 Worker 从未受影响)。它还期望可识别的 User-Agent。目录刷新是手动的(无定时任务):每季度一次,或当上游存在但搜索中未显示的数据流出现时立即刷新。流程:上述三个种子命令。数据查询始终是实时的,因此只有搜索目录可能过期——且其时效在来源追溯中公开。
评估
@sbissoli/mcp-evals:evals/fixtures/queries.ts 中有 24 个固定用例,在 npm test 中离线验证。使用真实模型运行(npm run eval)会使用 Anthropic API,需要 ANTHROPIC_API_KEY(没有它,会退出并显示说明)。2026-08-07 运行:top-1 100% (24/24) — evals/results/。
端到端:evals/e2e/evaluation.xml 中包含 10 个复杂问题,每个问题都有单一可验证答案,答案已针对生产环境手动验证(evals/e2e/validacao-respostas.md)。2026-08-07 运行(Sonnet):9/10 精确字符串;10/10 实质性 — evals/results/2026-08-07-e2e.md。
端点
路由 | 用途 |
| 落地页(服务标识 + 联系方式 — 公开) |
| 存活检查 |
| 版本、工具/资源/提示词的数量和名称、来源契约版本、当前部署(为 README 徽章提供数据) |
| 聚合使用情况(仅 MCP 端点;不包含 IP,不包含查询内容) |
| MCP Streamable HTTP |
安全
Snyk Agent Scan(2026-08-07):通过 — 报告见 security/。
许可证
代码:MIT。数据:ILOSTAT,CC BY 4.0(参见上文“数据许可证与署名”)。
隐私
托管服务的隐私政策:PRIVACY.md。
联系方式
Sidney da S. P. Bissoli — sbissoli76@gmail.com。本服务未经 ILO 认可。
Maintenance
Related MCP Servers
- AlicenseAqualityCmaintenanceMCP server for official statistics from Statistics Finland (Tilastokeskus) — the StatFin database, exposed through the PxWeb API. Search 3000+ tables, inspect their dimensions, and pull data as JSON-stat2.474MIT
- FlicenseNot gradedqualityBmaintenanceProvides macro-economic data from World Bank, IMF, FRED, OECD, and RBI through a unified get_indicator interface.1
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol (MCP) server that provides tools to query Eurostat APIs for European statistics data.10MIT
- AlicenseNot gradedqualityAmaintenanceSearch and query the Eurostat catalogue — EU economy, demography, trade, health, and NUTS regional data via MCP with 5 tools and 1 resource.1,1715Apache 2.0
Related MCP Connectors
ILOSTAT (International Labour Organization statistics) MCP — global labour
DBnomics MCP — meta-aggregator over 80+ stats providers
Statistics Netherlands (CBS / StatLine) OData MCP.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/SidneyBissoli/ilo-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server