Tauri Documentation MCP

io.github.fxckcode由 GitHub 账号 fxckcode 发布v0.2.0更新于 Oct 24, 2026

Read-only MCP server for official Tauri 2 documentation snapshots.

已验证STDIO仅桌面知识与记忆开发者工具

概览

AI 生成的概览

只读 MCP 服务器,让助手解析并查询内置的 Tauri 2 官方文档快照。

可以做什么
解析默认或指定的 Tauri 2 文档快照,返回修订版本、版本号与条目数等元数据,并对不支持的标识符返回稳定错误码。按关键词查询快照,获得有界且确定的结果,包含标题、小节、章节、规范链接、内容与版本敏感标记。为旧客户端保留兼容的搜索工具,沿用原有响应结构与限制。
适用场景
适合在开发 Tauri 2 桌面应用时,让助手离线查阅官方框架文档,而不依赖实时抓取网页。适用于 capabilities 等 Tauri 2 概念性问题,答案应来自固定且带版本的语料库。
运行要求
通过 npm 包 tauri-docs-mcp 以 stdio 在本地运行,可用 npx 或全局安装启动。需要 Node.js 20.19 或更高版本以及 npm 10 或更高版本。无需认证、API 密钥、请求头或环境变量;除非设置 TAURI_DOCS_MCP_DIAGNOSTICS=1,否则诊断关闭。
安装前请注意
文档是随包提交的快照,可能落后于当前 Tauri 版本;源修订不可变,更新需使用新快照。它只读,不抓取网址、不写文件、不执行代码,因此无法对照实际项目验证行为。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Tauri Documentation MCP,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

tauri-docs-mcp

[npm version]

A read-only Model Context Protocol (MCP) server for resolving and querying a checked-in snapshot of official Tauri 2 documentation.

Requirements

  • Node.js 20.19 or newer (supported Node LTS)
  • npm 10 or newer

The committed package-lock.json is authoritative. Use npm install for local development and dependency changes; CI and reproducible installs use npm ci. Lockfile changes must be committed with dependency changes.

Install and run

Install the published package:

bash
npm install --global tauri-docs-mcp

Or install it in a project and invoke the binary from node_modules/.bin:

bash
npm install tauri-docs-mcpnpx tauri-docs-mcp

Build from a checkout, then run the compiled stdio server:

bash
npm installnpm run buildnode dist/src/index.js

Configure an MCP client to launch the installed binary over stdio:

json
{  "mcpServers": {    "tauri-docs": {      "command": "tauri-docs-mcp"    }  }}

Portable configurations for generic MCP clients, Claude Desktop, Cursor, and VS Code are in examples/mcp/. They pin the package version and use stdio only. Installable agent guidance is in skills/tauri-docs-mcp/SKILL.md.

The server writes MCP JSON-RPC messages only to stdout. It does not start an HTTP listener. Diagnostics are disabled by default; opt in with TAURI_DOCS_MCP_DIAGNOSTICS=1 and they are written to stderr as event names only (never request arguments, corpus content, secrets, or PII).

Tool contract

The server exposes two stable tools and one backwards-compatible legacy tool.

resolve_tauri_docs

Resolve the default snapshot or an explicit identifier:

json
{}
json
{ "identifier": "tauri@2" }

Supported identifiers are tauri, tauri@2, and the immutable snapshot ID tauri-2@58194ceb69424c4332b2780b196ced3a6fffb32b. Resolution is deterministic and returns snapshot, source revision, generated-at, version, and entry-count metadata. Unsupported identifiers return UNSUPPORTED_SNAPSHOT.

query_tauri_docs

Query content from the default or selected snapshot:

json
{ "query": "capabilities", "snapshot": "tauri@2", "limit": 3 }

query is required and must contain 1–200 non-whitespace characters and at most 16 whitespace-separated terms. snapshot is optional and accepts the resolver identifiers. limit is an optional integer from 1–10 (default 5). Results are bounded, deterministic, and include title, heading, section, canonical URL, content, corpus snapshot, source revision, Tauri version, and versionSensitive. Empty matches return results: [], not an application error. Inputs reject unknown fields.

Both tools are read-only and idempotent. They read only the checked-in corpus; there is no live fetching or arbitrary URL access.

Resource and lifecycle bounds

The shared tool contract enforces a 200-character query, 16 terms, 10 results, 1,200-character snippets, 8 KiB corpus entries, and 32 KiB serialized tool responses. The stdio frame buffer is capped at 64 KiB. EOF, transport errors, SIGINT, and SIGTERM share an idempotent shutdown path with a one-second cleanup bound; in-flight work is allowed to settle or is abandoned at that bound.

search_tauri_docs (compatibility)

Existing clients can continue to call:

json
{ "query": "capabilities", "limit": 3 }

It remains supported with its existing response shape and limits. New clients should use resolve_tauri_docs followed by query_tauri_docs.

Application errors are returned with stable discriminated codes such as INVALID_INPUT, INVALID_QUERY, INVALID_LIMIT, and UNSUPPORTED_SNAPSHOT; protocol errors remain MCP protocol errors.

Product boundary

This package is intentionally:

  • read-only;
  • stdio-only;
  • limited to its checked-in corpus; and
  • constrained to official Tauri 2 sources under https://v2.tauri.app/.

It never fetches user-controlled URLs, writes files, executes arbitrary code, controls a Tauri runtime, provides hosted HTTP, authenticates users, or emits telemetry. See docs/architecture.md for the module seams.

Development commands

bash
npm install          # install from package-lock.jsonnpm run typecheck    # TypeScript validationnpm run build        # compile runtime files to dist/npm test             # run the full Vitest suitenpm run lint         # ESLintnpm run format       # format tracked source and documentationnpm run format:check # verify formatting without writingnpm pack --dry-run   # inspect the publish allowlistnpm run package:smoke -- /path/to/tauri-docs-mcp-0.1.0.tgz # test a packed install

The pull-request workflow runs the same commands from a clean checkout. To reproduce its package step locally, create a tarball and pass its path to the smoke test:

bash
mkdir -p .tmp/packageTARBALL=$(npm pack --json --pack-destination .tmp/package | node -e "let s=''; process.stdin.on('data', d => s += d).on('end', () => process.stdout.write(JSON.parse(s)[0].filename))")npm run package:smoke -- ".tmp/package/$TARBALL"rm -rf .tmp

See CONTRIBUTING.md for contribution rules and SUPPORT.md for supported use cases. Report vulnerabilities privately as described in SECURITY.md.

Releases and registry

The release workflow runs from a version tag and checks package, immutable corpus metadata, registry metadata, and the pack allowlist before publishing. npm publishing uses provenance/trusted publishing where enabled, then runs a fresh published-package smoke gate. Official MCP Registry publication is a separately protected environment chained after the successful npm job. No release is published from pull requests. See CHANGELOG.md for the release and MCP contract-change process.

Corpus maintenance

The runtime reads only the checked-in generated snapshot under corpus/; it never fetches documentation URLs. The approved manifest records canonical URLs, section hierarchy, Tauri version, source revision/freshness metadata, and a SHA-256 hash for each concise excerpt. The source revision is immutable, so a future snapshot must use a new tauri-2@<revision> directory.

After an approved source review, regenerate and validate deterministically:

bash
npm run ingest:docsnpm run validate:corpus

validate:corpus fails if the manifest is unsafe or incomplete, if content hashes drift, or if the generated artifact differs from its manifest. Source and license attribution is preserved in corpus/NOTICES.md.

Sources

来源:README.md,提交 d56a3a3

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v0.2.0最新Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分