Apple TV MCP

io.github.trevor-nichols由 GitHub 帳號 trevor-nichols 發布v0.2.0更新於 Oct 24, 2026

Local MCP server for semantic Apple TV control with optional screenshots.

已驗證STDIO僅桌面位置與生活媒體與設計

概覽

AI 產生的概覽

本機 MCP 伺服器,讓 AI 助理控制 Apple TV:開啟 App、導覽、播放、輸入文字、調整音量與電源,並可選擇截圖。

可以做什麼
讀取裝置、連線、播放與媒體狀態,檢視可用能力與已安裝的 App。依名稱或 bundle 識別碼開啟 App,並開啟 URL 或深層連結。按下遙控器按鍵(方向、選擇、返回、首頁、選單)操作 tvOS。控制播放:播放、暫停、停止、下一個、上一個、跳到指定位置、快轉或倒轉。在已聚焦的 tvOS 輸入欄位輸入文字,設定或調整音量,開啟或關閉 Apple TV。可選擇截圖並以 MCP 原生影像內容回傳,讓多模態助理看見畫面。
適用情境
適合讓助理實際操作 Apple TV:啟動 App、在 App 內搜尋、控制播放與音量,或操作沒有直接 API 的介面。截圖選項適合需要在操作後確認畫面上實際結果的多模態助理。
執行需求
以 stdio 在本機執行,需要 Python 3.14,透過 uv 或 pipx 安裝。需先用 atvremote wizard 配對 Apple TV,再用 configure 指令選擇裝置;電腦與 Apple TV 須在同一個區域網路。截圖需另裝 appletv-screenshot 輔助程式,並透過 pymobiledevice3 remote pair 另行進行開發者配對。不需要雲端帳號、OAuth 或 HTTP 端點。
安裝前請注意
助理會改變真實裝置狀態:開關機、音量、播放,以及向已聚焦欄位輸入文字。截圖會擷取畫面上的所有內容,包括選單與帳號名稱,並以影像內容傳送給模型;只在明確要求時才會截圖。配對憑證留在本機,不作為 MCP 參數。受保護的影片可能顯示為黑畫面。每個伺服器設定只控制一台 Apple TV。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Apple TV MCP,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

Apple TV MCP: A local MCP server that lets AI agents control — and see — your Apple TV

[Apple TV MCP — AI control and visual navigation for Apple TV]

Open apps, navigate tvOS, control playback, type searches, adjust volume, manage power, and take screenshots so a multimodal agent can actually inspect what happened.

text
You:Open YouTube and search for OpenAI.
Agent:→ opens YouTube→ takes a screenshot→ sees the current interface→ navigates to Search→ types "OpenAI"→ takes another screenshot→ verifies the results

Apple TV MCP turns your Apple TV into a locally controlled, visually observable device for MCP-capable AI agents.

No hosted backend. No custom Apple TV app. No cloud account.


Why Apple TV MCP?

Most Apple TV automation is blind.

A script can press Right or Select, but it usually has no idea what appeared on the screen afterward.

Apple TV MCP combines semantic control with point-in-time visual observation.

Traditional Apple TV automationApple TV MCP
Send blind remote commandsTake screenshots between actions
Build app-specific scriptsNavigate arbitrary tvOS interfaces
Guess whether an action workedInspect the screen and verify
Custom integration per AI systemStandard MCP tool interface
Remote commands onlyApps, playback, text, power, volume, navigation, and vision

The result is a feedback loop an AI agent can actually use:

text
screenshot    ↓model sees tvOS    ↓chooses an action    ↓press / type / open    ↓screenshot again    ↓verify

Semantic tools are still preferred whenever possible. Screenshots make the difference when the task requires navigating an interface that does not expose a direct API.


Install in seconds

Apple TV MCP requires Python 3.14.

Recommended

bash
uv tool install appletv-mcp

Or:

bash
pipx install appletv-mcp

Then pair your Apple TV:

bash
atvremote wizard

Configure Apple TV MCP:

bash
appletv-mcp configure

Check the setup:

bash
appletv-mcp doctor

And start the MCP server:

bash
appletv-mcp serve

From source

bash
git clone https://github.com/trevor-nichols/appletv-mcp.gitcd appletv-mcpuv sync --lockeduv run appletv-mcp configureuv run appletv-mcp doctoruv run appletv-mcp serve

What can it do?

Apple TV MCP exposes fourteen tools grouped around what an agent actually wants to accomplish.

See

  • Take a screenshot of the current Apple TV screen
  • Read device, connection, playback, and media state
  • Inspect available Apple TV capabilities

Apps

  • List installed applications
  • Open an application by name
  • Open an application by bundle identifier
  • Open deep links and custom application URLs

Navigate

  • Up
  • Down
  • Left
  • Right
  • Select
  • Back
  • Home
  • Menu
  • Other supported remote actions

Remote navigation is intentionally treated as non-idempotent. Apple TV MCP does not blindly replay navigation commands after an uncertain connection failure.

Playback

  • Play
  • Pause
  • Toggle play/pause
  • Stop
  • Next
  • Previous
  • Seek to an absolute position
  • Skip forward or backward

Text

Type directly into a focused tvOS text field.

This is useful for:

  • Search
  • Usernames
  • App navigation
  • Query entry

Volume

  • Read volume when available
  • Set an absolute volume level
  • Adjust volume relatively

Power

  • Turn the Apple TV on
  • Turn the Apple TV off

Power operations use different retry semantics so a reconnect attempt cannot accidentally wake a device immediately after a successful power-off command.


Give your agent eyes

The optional screenshot backend is what makes Apple TV MCP more than a remote control.

The MCP tool:

text
apple_tv_screenshot

returns the current Apple TV screen as native MCP image content.

That means a multimodal MCP client can call the tool and inspect the returned image directly.

For example:

text
Agent:apple_tv_screenshot()
→ sees the Apple TV Home Screen→ sees YouTube highlighted
apple_tv_press(button="select")
apple_tv_screenshot()
→ sees the YouTube interface

The model does not need access to a local screen.png path and does not receive base64 inside a text response.

The PNG itself is returned through MCP.

Screenshots are point-in-time

Apple TV MCP does not continuously watch the screen.

A screenshot describes what was rendered at the moment it was captured.

If the agent performs another action afterward, the previous screenshot may already be stale.

The intended pattern is:

text
observe→ act→ observe→ verify

Enable screenshots

Screenshot support is optional.

Apple TV control continues to work normally without it.

Install the separate helper:

bash
uv tool install appletv-screenshot

The screenshot system uses a separate Apple developer / RemoteXPC pairing from the pairing used by pyatv.

Pair for developer access:

bash
pymobiledevice3 remote pair

Then configure the screenshot helper for one Apple TV:

bash
appletv-screenshot configure --udid <UDID>

Verify everything together:

bash
appletv-mcp doctor

A healthy installation will report both Apple TV control and screen capture.

The screenshot helper has its own configuration, dependencies, and lifecycle. pymobiledevice3 is not imported by the main appletv-mcp package.

For deeper screenshot setup and transport troubleshooting, see:

text
sidecars/appletv-screenshot/README.md

Quick start

The complete happy path is:

bash
# Installuv tool install appletv-mcp
# Pair for Apple TV controlatvremote wizard
# Choose the Apple TVappletv-mcp configure
# Optional: install visual observationuv tool install appletv-screenshot
# Optional: developer pairing for screenshotspymobiledevice3 remote pairappletv-screenshot configure --udid <UDID>
# Verifyappletv-mcp doctor
# Run the MCP serverappletv-mcp serve

Connect your MCP client

Apple TV MCP uses local stdio MCP transport.

Any MCP client capable of launching a local stdio server can use it.

A typical configuration looks like:

json
{  "mcpServers": {    "appletv-mcp": {      "command": "appletv-mcp",      "args": ["serve"]    }  }}

If Apple TV MCP is running from a cloned repository instead:

json
{  "mcpServers": {    "appletv-mcp": {      "command": "uv",      "args": [        "--directory",        "/absolute/path/to/appletv-mcp",        "run",        "appletv-mcp",        "serve"      ]    }  }}

The server does not expose an HTTP endpoint and does not require OAuth.


Tools

ToolPurpose
apple_tv_statusRead structured device and playback state
apple_tv_capabilitiesInspect normalized feature availability
apple_tv_list_appsList launchable applications
apple_tv_powerTurn the Apple TV on or off
apple_tv_open_appOpen an application
apple_tv_open_urlOpen a URL or deep link
apple_tv_pressPress Apple TV remote buttons
apple_tv_playbackControl playback
apple_tv_seekSeek to an absolute playback position
apple_tv_skipSkip forward or backward
apple_tv_set_textReplace focused keyboard text
apple_tv_set_volumeSet an absolute volume
apple_tv_adjust_volumeAdjust volume relatively
apple_tv_screenshotReturn one screenshot as MCP image content

The screenshot tool is the only tool that returns image content rather than a structured result.


How it works

Apple TV MCP keeps control and visual observation intentionally separate.

text
                         AI Agent                            │                            ▼                      Apple TV MCP                      /           \                     /             \                    ▼               ▼              semantic control   screen capture                    │               │                  pyatv      appletv-screenshot                    │               │                    │         pymobiledevice3                    │               │                    │          RemoteXPC / DVT                    │               │                    └──── Apple TV ─┘

Control

Apple TV control is provided through pyatv.

Apple TV MCP adds a semantic application layer on top for:

  • deterministic app resolution
  • capability checking
  • connection lifecycle
  • safe retry behavior
  • non-idempotent command protection
  • normalized MCP results

The stable Apple TV identifier is authoritative.

The last known IP address is only an optimization. If the Apple TV changes addresses, Apple TV MCP can rediscover it by identifier and update the preferred host.

Vision

Screenshots use the separate appletv-screenshot helper.

The helper uses pymobiledevice3 to reach Apple's developer services over RemoteXPC and request a screenshot through DVT.

Its default transport strategy is:

text
macOS:native → userspace → tunneld
Linux / Windows:userspace → tunneld

The normal Wi-Fi userspace path does not require root or a permanently running tunnel daemon.

The helper exists as a separate process so its protocol stack, dependencies, pairing records, and failure modes remain isolated from Apple TV control.

pymobiledevice3 is confined to the separately distributed appletv-screenshot helper. The main appletv-mcp package does not import or bundle it; the two processes communicate through a narrow command-line/file contract.


Designed for agents

The MCP interface intentionally exposes semantic operations rather than raw Apple protocols.

An agent should think:

text
open YouTubepause playbackseek to 2:00type "Severance"set volume to 35%take a screenshot

not:

text
send Companion commandcall MRP endpointconstruct RemoteXPC request

When a semantic operation exists, use it.

Visual navigation is the fallback for interfaces that require it.


Privacy and security

Apple TV MCP is designed to remain local.

  • No hosted Apple TV MCP backend
  • No cloud account
  • MCP uses local stdio transport
  • Apple TV pairing credentials stay on the user's machine
  • RemoteXPC pairing records stay with the screenshot helper
  • Credentials are never MCP parameters
  • Credentials are never returned to the model
  • Keyboard text is not emitted into normal logs
  • Screenshots are captured only when explicitly requested
  • Screenshot bytes are not logged
  • Screenshots are stored only in a private temporary directory during capture
  • Temporary screenshot files are deleted after the MCP result is created
  • Screenshot capture does not run automatically after commands
  • The helper is launched without a shell
  • No DRM circumvention is attempted

Debug mode also keeps raw pyatv protocol logging disabled because low-level Companion traffic can contain sensitive keyboard and pairing payloads.


Protected video

Streaming applications may protect video using DRM.

In that case, screenshots can contain:

text
black videoblank videoredacted video

while menus or playback controls remain visible.

That is expected.

Apple TV MCP does not interpret a black protected video region as proof that:

  • playback failed
  • the Apple TV turned off
  • screenshot capture failed

and it does not attempt to bypass DRM.


Limitations

Apple TV MCP intentionally has a narrow initial scope.

One Apple TV

Each server configuration controls one Apple TV.

Multi-device routing is not currently part of the public MCP interface.

Screenshots are not video

apple_tv_screenshot captures one frame at a time.

There is no:

  • continuous stream
  • background screen monitoring
  • screen recording
  • automatic screenshot loop

Focus is visual, not semantic

pyatv does not provide a universal signal for the currently highlighted tvOS element.

An agent can use screenshots to infer focus where appropriate.

media_app is not foreground_app

Apple TV status may identify the application associated with current media metadata.

That does not independently guarantee which application is visually in the foreground.

Apple developer services can change

Screenshot support relies on Apple developer protocols exposed through pymobiledevice3.

tvOS changes may require future compatibility updates.

Screenshot support is optional

Every non-screenshot Apple TV MCP tool works without the screenshot helper installed.


Configuration

Apple TV MCP stores application configuration in the platform-standard config directory.

Typical settings include:

json
{  "device_identifier": "...",  "device_name": "Living Room",  "preferred_host": "192.168.1.10",  "scan_timeout_seconds": 5.0,  "command_timeout_seconds": 15.0,  "screen_capture": {    "command": "appletv-screenshot",    "timeout_seconds": 20.0,    "max_image_bytes": 33554432  }}

Pairing credentials are not stored in this file.

If an MCP host launches processes with a minimal PATH, set screen_capture.command to the absolute path of the screenshot helper.

Existing configuration files from Apple TV MCP v0.1 remain compatible.


Doctor

Run:

bash
appletv-mcp doctor

to diagnose the complete installation.

It checks areas such as:

text
configurationpyatv storageApple TV discoverystable device identityconnectioncapabilitiesscreenshot helperscreenshot helper contractscreen-capture targetreal screenshot capture

Screenshot support is optional.

If the helper is not installed, Doctor reports it as skipped rather than treating Apple TV control as broken.


Troubleshooting

Apple TV not found

Confirm:

  • the Apple TV is powered on
  • the computer and Apple TV are on the same local network
  • atvremote wizard completed successfully

Then rerun:

bash
appletv-mcp configureappletv-mcp doctor

Apple TV IP changed

That is expected.

Apple TV MCP identifies the configured device by its stable identifier rather than trusting an old IP address.

App will not open

Use:

text
apple_tv_list_apps

to see the applications currently exposed by the device.

Application-name matching is deterministic rather than fuzzy.

Text entry fails

A text field must already be focused on the Apple TV.

Screenshot helper not found

Install it:

bash
uv tool install appletv-screenshot

or configure Apple TV MCP with its absolute path.

Screenshot target is not configured

Run:

bash
appletv-screenshot configure --udid <UDID>

Screenshot pairing fails

Developer screenshot pairing is separate from atvremote.

Run:

bash
pymobiledevice3 remote pair

Screenshot is black

Protected content may intentionally hide its video frame.

Try opening a tvOS menu or application interface and capture again.


Development

Clone the repository:

bash
git clone https://github.com/trevor-nichols/appletv-mcp.gitcd appletv-mcp

Install:

bash
uv sync --locked

Run the complete root quality gate:

bash
uv run ruff check .uv run ruff format --check .uv run pyrightuv run pytestuv build

The screenshot helper is a separate Python project:

bash
cd sidecars/appletv-screenshotuv sync --lockeduv run ruff check .uv run ruff format --check .uv run pyrightuv run pytest

The root package deliberately does not depend on or bundle pymobiledevice3.


Live tests

Normal tests use fakes and do not require Apple hardware.

Read-only Apple TV integration tests are explicitly opt-in:

bash
APPLE_TV_INTEGRATION_TESTS=1 uv run pytest -m live

Tests that can change Apple TV state require an additional opt-in:

bash
APPLE_TV_INTEGRATION_TESTS=1 \APPLE_TV_LIVE_WRITES=1 \uv run pytest -m live

Never enable the live-write suite against a device you do not intend to control.


Contributing

Contributions are welcome.

Before opening a pull request:

bash
uv run ruff check .uv run ruff format --check .uv run pyrightuv run pytestuv build

If your change affects the screenshot helper, run its independent quality gate as well.

Please preserve the project's core architecture:

text
control      = pyatvobservation  = external screenshot helperMCP          = semantic interface presented to the agent

Avoid exposing raw Apple protocol details through the MCP contract unless there is a clear semantic reason.


License

This repository contains two separately distributed components.

Apple TV MCP

appletv-mcp is licensed under the MIT License.

It does not import, bundle, or distribute pymobiledevice3.

Apple TV Screenshot

The optional appletv-screenshot helper under sidecars/appletv-screenshot/ is licensed under GPL-3.0-or-later.

The helper directly uses pymobiledevice3, which is also licensed under GPL-3.0-or-later.

The two components communicate through a one-shot subprocess interface.

See LICENSING.md for the repository-wide map.


Built for a simple idea

AI agents are much more useful when they can verify the effects of their actions.

Apple TV MCP gives them both sides of that loop:

text
control the Apple TV        +see the Apple TV

So instead of blindly pressing buttons, an agent can interact with tvOS, inspect the result, and decide what to do next.

來源:README.md,提交 930a9bc

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

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

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分