Deckhand

Deckhand

Enables Claude to build and preview mobile apps on multiple iOS and Android devices simultaneously, with live streaming and touch control, all via MCP.

Category
访问服务器

README

Deckhand

Ask Claude for your app on any device — get a link.

Deckhand is an MCP server that runs on a Mac. Connect it to Claude (claude.ai, Claude Code, Routines — any MCP client) and ask:

"Test the onboarding screens on iOS 26 and Android 14 for PR #42"

You get back one calm page showing every device live, with full touch control — shareable publicly or behind a PIN. Claude can also see and drive the devices itself (screenshot, accessibility tree, tap/type) before it hands you the link.

How it works

  1. You ask — Claude calls start_preview with an app id, a ref/PR, and devices.
  2. Deckhand builds — checks out the branch into a worktree (or builds a registered local checkout in place), builds once per platform, installs on every device.
  3. Devices boot in parallel — iOS simulators via simctl, Android emulators via avdmanager/adb.
  4. You get a link — a stable per-app share URL streaming all devices live, riding a Cloudflare tunnel. No VPN, no WebRTC, no TURN — if a network can reach claude.ai, it can view and control a preview.

Architecture

One Node process owns everything. Nothing but cloudflared is reachable from outside the machine.

 claude.ai / Claude Code / any MCP client      share-link viewers (any browser)
        │ HTTPS                                        │ HTTPS/WSS
        └───────────────────┬──────────────────────────┘
                            ▼
          cloudflared named tunnel → http://127.0.0.1:4300
                            │
┌───────────────────────────▼── deckhand server (loopback only) ──┐
│                                                                 │
│  /mcp/<token>            MCP tools, per-person token, role-gated│
│  /s/<shareId>            viewer page (device grid + controls)   │
│  /s/<shareId>/dev/<id>/* scoped proxy → that device's stream    │
│                                                                 │
│  auth → mcp tools → preview engine → devices → streaming        │
│           │             │               │          │            │
│       audit log    git worktrees    simctl /   serve-sim (iOS)  │
│                    + build recipes  adb        adb-screencap    │
│                                                (Android)        │
└─────────────────────────────────────────────────────────────────┘

 on-disk: ~/.deckhand/{config.yaml, apps.yaml, tokens.yaml, state.json, audit.jsonl}

Building blocks

Module What it does
server/src/mcp/ The MCP surface: previews, screenshots, UI tree, test runs, app registration
server/src/engine/ Preview state machine, build recipes (Expo / RN / NativeScript), app-type detection, worktrees, dev-server lifecycle
server/src/devices/ iOS (simctl) and Android (avdmanager/emulator/adb) control, tool env resolution
server/src/streaming/ Swappable StreamingBackend seam — serve-sim H.264 for iOS, adb-screencap for Android (scrcpy is the planned upgrade)
server/src/share/ Share ids, PIN protection, and the scoped HTTP+WS proxy (video + input, nothing else)
server/src/github/ Credential ladder: PAT → GitHub App → ambient gh → anonymous (public repos)
server/src/cli.ts deckhand CLI: init, serve, doctor, token, app, env
viewer/ The single calm page: WebCodecs stream client, touch/keyboard input, device picker

Stack: Node ≥ 22, TypeScript, ESM. No database, no SPA framework beyond the one viewer page, a ruthlessly short dependency list.

Two ways to run an app

  • Git mode — Deckhand clones the repo, fetches any ref or PR into a detached worktree, and builds there. Fully self-contained.
  • Local mode (daily dev loop) — register an existing checkout with deckhand app add <id> --path <dir>. Built in place, never mutated: Deckhand reads the checkout's git state but never writes to it. restart_preview (or the viewer's Rebuild button) rebuilds on the same booted devices.

Security model

  • Everything binds loopback; the only way in is the Cloudflare named tunnel.
  • No tokenless paths: per-person MCP tokens, per-app share links (optionally PIN-gated).
  • The MCP surface is capability-bounded — no arbitrary commands, only pre-registered apps and their repos' refs. Every call lands in an append-only audit log.
  • Secrets never travel through MCP; tokens never appear in argv, URLs, or logs.

Status

Phases 1, 2 & 2.5 done — iOS + Android multi-device previews, local dev mode, and agent-driven test runs, validated end-to-end on real hardware over a live tunnel (168 tests, CI green). Next: Phase 3 (password shares, agent-led onboarding contract) and Phase 4 (ops hardening + AI setup runbook).

The complete build plan lives in PLAN.md.

Run it (dev)

npm install
npm run build --workspace @deckhand/viewer      # build the viewer once
deckhand init --hostname <host> --github-app-id <id> --github-app-pem <path.pem>
deckhand token add <you> --role admin           # prints your connector URL
deckhand app add <id> github.com/owner/repo     # or: --path <local-checkout>
npm run dev                                     # or: deckhand serve
deckhand doctor --smoke                         # end-to-end check on the Mac

License

Deckhand is released under the MIT License.

推荐服务器

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 模型以安全和受控的方式获取实时的网络信息。

官方
精选