Mcp Server Tauri

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

A Model Context Protocol server for use with Tauri v2 applications

已验证STDIO仅桌面浏览器自动化开发者工具

概览

AI 生成的概览

让 AI 助手通过操作 Tauri v2 桌面应用的 webview 界面、IPC、日志和移动设备来构建、测试和调试应用。

可以做什么
  • 检查并操作应用界面:查找元素、点击、滚动、输入、等待、读取计算样式、截图、获取 DOM 快照、可视化选取元素以及管理窗口
  • 在 webview 中执行 JavaScript,并查看或操作原生 Windows 对话框
  • 处理 Tauri IPC:执行命令、读取后端状态、发送事件,以及启动或停止 IPC 监控以捕获通信
  • 读取控制台、Android logcat、iOS 和系统日志,并列出 Android 设备与 iOS 模拟器
  • 按端口或 bundle ID 管理多个运行中应用的自动化会话,并获取桥接插件的安装说明
适用场景
适合在开发或调试 Tauri v2 应用时使用,让助手直接复现界面流程、检查 IPC 调用、抓取日志或确认移动端目标,而不必由你手动执行每一步。
运行要求
通过 npm 包以 stdio 在本地运行,需要 Node.js。Tauri 应用需集成 tauri-plugin-mcp-bridge Rust 插件(调试构建),服务器通过 WebSocket(如 9223 端口)与其通信。未声明需要账号、API 密钥或环境变量。
安装前请注意
助手可在 webview 中执行 JavaScript、调用 Tauri IPC 命令、发送事件并在应用中点击或输入,因此可能改变应用状态和数据。桥接插件应仅用于调试构建。README 说明这是另一项目的独立下游分支,请确认所信任的分发来源。

安装

在 SourceWeft 中

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

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

其他 MCP 客户端

参照 仓库 中的启动说明。

README

@hushlor/tauri-mcp-server

[npm version] [License: MIT]

A Model Context Protocol (MCP) server that enables AI assistants like Claude, Cursor, and Windsurf to build, test, and debug Tauri® v2 applications.

📖 Full Documentation

Independent downstream fork: Hushlor maintains this distribution independently of hypothesi/mcp-server-tauri, preserving the upstream MIT license and attribution.

Features

CategoryCapabilities
🎯 UI AutomationScreenshots, clicks, typing, scrolling, element finding, visual element picker
🔍 IPC MonitoringCapture and inspect Tauri IPC calls in real-time
📱 Mobile DevList Android emulators & iOS simulators
📋 LogsStream console, Android logcat, iOS, and system logs

Quick Start

1. Add the MCP Bridge Plugin to Your Tauri App

bash
cargo add tauri-plugin-hushlor-mcp-bridge --rename tauri-plugin-mcp-bridge --version 0.14.0
rust
// src-tauri/src/main.rsfn main() {    let mut builder = tauri::Builder::default();
    #[cfg(debug_assertions)]    {        builder = builder.plugin(tauri_plugin_mcp_bridge::init());    }
    builder        .run(tauri::generate_context!())        .expect("error while running tauri application");}

Note: The npm package @hushlor/tauri-plugin-mcp-bridge is optional—only needed if you want to call the plugin from your app's frontend code. The MCP server communicates with the Rust plugin directly via WebSocket.

2. Configure Your AI Assistant

Use aix to add the server to your AI assistant:

bash
npx -y @a1st/aix add mcp tauri --command 'npx @hushlor/tauri-mcp-server' --user

Supported clients: claude-code, cursor, windsurf, vscode, cline, roo-cline, claude, zed, goose, warp, codex

Terminal CLI

If you want to call the same tools directly from a shell, install the companion CLI package:

bash
npm install -g @hushlor/tauri-mcp-clitauri-mcp driver-session start --port 9223tauri-mcp driver-session status --json

The CLI keeps the underlying MCP server warm in the background so stateful commands such as driver_session work across separate invocations.

Multi-App Support

The MCP server supports connecting to multiple Tauri apps simultaneously. Each app runs on a unique port, and the most recently connected app becomes the "default" app.

Key Features:

  • Connect to multiple apps on different ports
  • Default app used when no appIdentifier specified
  • Target specific apps using port number or bundle ID
  • Stop individual sessions or all sessions at once

Example Usage:

javascript
// Connect to first appawait driver_session({ action: "start", port: 9223 })
// Connect to second appawait driver_session({ action: "start", port: 9224 })
// Check status - shows both apps with default indicatorawait driver_session({ action: "status" })
// Use default app (most recent - port 9224)await webview_screenshot()
// Target specific app by portawait webview_screenshot({ appIdentifier: 9223 })
// Stop specific appawait driver_session({ action: "stop", appIdentifier: 9223 })
// Stop all appsawait driver_session({ action: "stop" })

Available Tools (22 total)

Setup & Configuration

ToolDescription
get_setup_instructionsGet setup/update instructions for the MCP Bridge plugin

UI Automation

ToolDescription
driver_sessionStart/stop/status automation session
webview_find_elementFind elements by CSS selector, XPath, text, or ref ID
read_logsRead console, Android, iOS, or system logs
webview_interactClick, scroll, swipe, focus, long-press
webview_screenshotCapture webview screenshots (JPEG default)
native_dialog_snapshotInspect app-owned native Windows dialog chains and navigation controls
native_dialog_interactInvoke, set paths, or select native Windows dialog controls
webview_keyboardType text or send key events
webview_wait_forWait for elements, text, or events
webview_get_stylesGet computed CSS styles
webview_execute_jsExecute JavaScript in webview
webview_dom_snapshotGet structured DOM snapshot (accessibility or structure)
webview_select_elementVisual element picker — user clicks an element, returns metadata + screenshot
webview_get_pointed_elementGet metadata for element user Alt+Shift+Clicked
manage_windowList windows, get info, or resize

IPC & Plugin

ToolDescription
ipc_execute_commandExecute Tauri IPC commands
ipc_get_backend_stateGet app metadata and state
ipc_monitorStart/stop IPC monitoring
ipc_get_capturedGet captured IPC traffic
ipc_emit_eventEmit custom events

Mobile Development

ToolDescription
list_devicesList Android devices and iOS simulators

Links

License

MIT © Hushlor. Original upstream copyright and attribution are preserved in the package LICENSE; see hypothesi/mcp-server-tauri for provenance.


Trademark Notice

TAURI® is a registered trademark of The Tauri Programme within the Commons Conservancy. https://tauri.app/

This project is not affiliated with, endorsed by, or sponsored by The Tauri Programme within the Commons Conservancy.

来源:packages/mcp-server/README.md,提交 06ff367

工具

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

版本历史

3
  1. v0.14.3最新Oct 6, 2026
  2. v0.14.2Oct 6, 2026
  3. v0.14.0Sep 16, 2026

评分

已满足适用检查项的 50%

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

  • 近 30 天内可连通25 分

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

  • 已声明认证方式10 分

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

  • 已列出工具15 分

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

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