CA

cursortouch/android-mcp

Developer tools

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기

906 stars 127 forks 품질 76 트렌드 43MIT

안드로이드 기기와 상호작용하기 위한 MCP 서버입니다.

개요

AI 에이전트와 안드로이드 기기 간의 다리 역할을 하는 가볍고 오픈소스 도구입니다. MCP 서버로 실행되어, LLM 에이전트가 전통적인 컴퓨터 비전 파이프라인이나 미리 프로그래밍된 스크립트에 의존하지 않고 실제 작업을 수행할 수 있게 해줍니다. https://github.com/user-attachments/assets/cf9a5e4e-b69f-46d4-8487-0f61a7a86d67 - ADB와 Android Accessibility API를 통해 UI 요소와 상호작용: 앱 실행, 탭, 스와이프, 텍스트 입력, 뷰 계층 구조 읽기. - 모든 언어 모델에서 작동하며, 세밀하게 조정된 CV 모델이나 OCR 파이프라인이 필요하지 않습니다. - 제스처, 키 입력, 캡처, 장치 상태, 셸 명령 실행을 위한 사전 구축된 도구들. - 동작 간 일반적인 지연 시간(예: 두 탭)은 장치 사양과 부하에 따라 범위가 있습니다. - 파이썬 3.13 - ADB (안드로이드 디버그 브리지) - 안드로이드 10+ (에뮬레이터/안드로이드 기기) 서버를 실행하기 전에 안드로이드 기기가 ADB에서 연결되어 인식되는지 확인하세요:

개요(AI 번역)

안드로이드-MCP의 클린룸 재구현: MCP AI 에이전트가 ADB를 통해 안드로이드 기기를 조작할 수 있게 하는 서버입니다.

adb만 있으면 됩니다. 장치에 아무것도 설치되지 않으며, 에 의존하지 않습니다 uiAutomator2.

도망쳐

Python 3.13과 adb(안드로이드 플랫폼 툴)가 필요합니다.

서버는 stdio에서 MCP로 말합니다. 클라이언트 설정에서는:

기기는 첫 번째 툴 호출 시 연결되어 있으므로, 서버가 시작됩니다. 아직 붙어 있지 않았다.

장치 선택

옵션이 없으면 첫 번째 물리적 기기를 사용하거나, 없을 때 에뮬레이터를 사용합니다.

옵션 환경 의미
--device SERIAL ANDROID_MCP_DEVICE 네트워크 내 장치의 시리얼, 또는 host:port
--connection auto|usb|wifi (별칭 --transport) ANDROID_MCP_CONNECTION 장치가 이름이 없을 때 선택하는 방법
--wifi [HOST] ANDROID_MCP_HOST 와이파이를 통한 ADB; HOST 또는 HOST:PORT, 기본적으로 포트 5555
--usb [SERIAL] USB를 통한 ADB, 선택적으로 특정 시리얼

선택권이 환경을 이깁니다. 기타 변수:

  • ANDROID_MCP_ADB_PATH는 adb 이진 변수를 지정합니다. 그렇지 않으면 adb를 PATH에서 찾고, 그 다음 다음에

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.

README

원문 README의 일부입니다. 원문 보기.

android-mcp-beta

Clean-room reimplementation of Android-MCP: an MCP server that lets an AI agent operate an Android device over ADB.

It needs only adb. Nothing is installed on the device, and there is no dependency on uiautomator2.

Run

Requires Python 3.13 and adb (Android platform-tools).

uv run android-mcp-beta

The server speaks MCP on stdio. In a client’s config:

{
  "mcpServers": {
    "android-mcp-beta": {
      "command": "uv",
      "args": ["--directory", "D:/Projects/android-mcp-beta", "run", "android-mcp-beta"]
    }
  }
}

The device is connected on the first tool call, so the server starts whether or not one is attached yet.

Choosing the device

With no options it uses the first physical device, or an emulator when there is none.

Option Environment Meaning
--device SERIAL ANDROID_MCP_DEVICE A serial, or host:port for a device on the network
--connection auto|usb|wifi (alias --transport) ANDROID_MCP_CONNECTION How to pick when no device is named
--wifi [HOST] ANDROID_MCP_HOST ADB over Wi-Fi; HOST or HOST:PORT, port 5555 by default
--usb [SERIAL] ADB over USB, optionally a specific serial

Options win over the environment. Other variables:

  • ANDROID_MCP_ADB_PATH names the adb binary. Otherwise adb is looked for on PATH, then in ANDROID_HOME, ANDROID_SDK_ROOT and the default Android Studio SDK folders.
  • SCREENSHOT_QUANTIZED=true reduces screenshots to 256 colours, which makes them smaller.

Tools

Tool Does
ListDevices, ConnectDevice, Device List, choose, or disconnect the device
Snapshot The interactive elements, each with a label and tap coordinates. use_vision adds a screenshot with the labels drawn on it; use_annotation=false leaves it clean
Click, LongClick, Swipe, Drag Touch input by coordinates
ClickBySelector Tap an element found by text, resourceId, className or description (exact match; resourceId may be the part after the slash), with index for the nth match
Type Type into a field. x and y tap it first; clear empties it first. Other scripts and emoji need the optional ADBKeyboard app (below)
Press A button: back, home, recent, volume up, enter, and so on
Notification Pull down the notification shade
Wait, WaitForElement Pause, or wait for an element to appear

Typing other scripts (optional)

Type uses adb shell input text, so on its own it types printable ASCII and the accented Latin letters Android can compose (é ñ ü ÿ and 107 others, not ç ß å ø). A newline presses Enter and a tab presses Tab. For anything else (CJK, Cyrillic, Arabic, emoji, ç), install the ADBKeyboard app on the device once:

adb install keyboardservice-debug.apk
GitHub에서 전체 README 보기

설치

This server does not publish a one-line install command.

Open the repository installation guide MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →

설정

{ "mcpServers": { "android-mcp-beta": { "command": "uv", "args": ["--directory", "D:/Projects/android-mcp-beta", "run", "android-mcp-beta"] } } }