MCP server for fast Android device interaction with scrcpy acceleration
Project description
device-manager-mcp
MCP server for fast Android device interaction with scrcpy acceleration.
Features
- Fast operations via scrcpy (~50ms latency)
- Automatic fallback to adb (~500ms) when scrcpy unavailable
- Screenshots, taps, swipes, typing - all device interactions
- Works with Claude Code and any MCP-compatible client
Installation
pip install device-manager-mcp
# For scrcpy acceleration (recommended):
pip install device-manager-mcp[scrcpy]
Prerequisites
- Python 3.11+
- Android device connected via USB
adbinstalled and in PATH- For scrcpy acceleration:
scrcpy3.x installed
Usage with Claude Code
Add to your .mcp.json:
{
"mcpServers": {
"device-manager": {
"command": "python",
"args": ["-m", "device_manager_mcp"]
}
}
}
Or add globally:
claude mcp add device-manager -s user -- python -m device_manager_mcp
Available Tools
| Tool | Description | Latency |
|---|---|---|
device_screenshot |
Capture screen as PNG | ~40ms (scrcpy) / ~500ms (adb) |
device_tap |
Tap at coordinates | ~50ms (scrcpy) / ~200ms (adb) |
device_swipe |
Swipe gesture | ~300ms |
device_type |
Type text | ~100ms |
device_press_key |
Press BACK, HOME, ENTER, etc. | ~50ms |
device_list |
List connected devices | ~100ms |
device_screen_size |
Get screen dimensions | ~10ms |
device_backend_status |
Check active backend | instant |
How It Works
The server automatically selects the best backend:
-
scrcpy backend (if available): Uses MYScrcpy library to communicate directly with scrcpy server on device. Provides ~50ms latency for screenshots and input.
-
adb backend (fallback): Uses standard
adbcommands. Works everywhere but slower (~500ms for screenshots).
Example
# Claude Code will automatically use these tools:
# Take a screenshot
device_screenshot()
# Tap at coordinates
device_tap(x=540, y=1200)
# Swipe down
device_swipe(start_x=540, start_y=800, end_x=540, end_y=1600)
# Type text
device_type(text="Hello World")
# Press back button
device_press_key(key="BACK")
Configuration
Environment Variables
DEVICE_MANAGER_LOG_LEVEL: Set logging level (DEBUG, INFO, WARNING, ERROR)
Multiple Devices
Specify device ID for multi-device setups:
device_tap(x=100, y=200, device="RFCW318P7NV")
Development
# Clone repository
git clone https://github.com/vladkarpman/device-manager-mcp
cd device-manager-mcp
# Install with dev dependencies
pip install -e ".[dev,scrcpy]"
# Run tests
pytest
License
MIT License - see LICENSE for details.
Related Projects
- mobile-mcp - Official Anthropic mobile MCP
- MYScrcpy - Python scrcpy client
- Claude Code - AI coding assistant
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file device_manager_mcp-1.0.1.tar.gz.
File metadata
- Download URL: device_manager_mcp-1.0.1.tar.gz
- Upload date:
- Size: 10.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b3a6f46fdbd110954b60afe86aa54a0674128057c3b2a8c506e30184c316df93
|
|
| MD5 |
d7503ed9287ace9d3316ba4e7b95d784
|
|
| BLAKE2b-256 |
eb6aaa38578afb628f953d3ebaf8ba62cc858f3fd7988f0c0245263727f59aa9
|
Provenance
The following attestation bundles were made for device_manager_mcp-1.0.1.tar.gz:
Publisher:
publish.yml on vladkarpman/device-manager-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
device_manager_mcp-1.0.1.tar.gz -
Subject digest:
b3a6f46fdbd110954b60afe86aa54a0674128057c3b2a8c506e30184c316df93 - Sigstore transparency entry: 821228990
- Sigstore integration time:
-
Permalink:
vladkarpman/device-manager-mcp@d4da2b350c980eaaeda532707891758165610d27 -
Branch / Tag:
refs/tags/v1.0.1 - Owner: https://github.com/vladkarpman
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d4da2b350c980eaaeda532707891758165610d27 -
Trigger Event:
push
-
Statement type:
File details
Details for the file device_manager_mcp-1.0.1-py3-none-any.whl.
File metadata
- Download URL: device_manager_mcp-1.0.1-py3-none-any.whl
- Upload date:
- Size: 12.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0db99acd9749d69a0d230d8d4f8c67aa5c55de4336d473507b796863b2060f5f
|
|
| MD5 |
88287613a7f83f41ab0b053665a2cb3a
|
|
| BLAKE2b-256 |
aff28a7dc834e1a49210bada652d6bd06539b14dbc9b1379f8f0719ece45a3b7
|
Provenance
The following attestation bundles were made for device_manager_mcp-1.0.1-py3-none-any.whl:
Publisher:
publish.yml on vladkarpman/device-manager-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
device_manager_mcp-1.0.1-py3-none-any.whl -
Subject digest:
0db99acd9749d69a0d230d8d4f8c67aa5c55de4336d473507b796863b2060f5f - Sigstore transparency entry: 821228992
- Sigstore integration time:
-
Permalink:
vladkarpman/device-manager-mcp@d4da2b350c980eaaeda532707891758165610d27 -
Branch / Tag:
refs/tags/v1.0.1 - Owner: https://github.com/vladkarpman
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@d4da2b350c980eaaeda532707891758165610d27 -
Trigger Event:
push
-
Statement type: