PocketMCP
Turn your Android phone into an MCP (Model Context Protocol) server. AI agents and desktop scripts can call your phone for live data and actions over LAN or Tailscale.
Power your agent
पब्लिशर का इंस्टॉल। PlugMCP एंडपॉइंट नहीं।
Host a copy with our keys and logs.
रजिस्ट्री में अभी कोई पैकेज्ड रिलीज़ नहीं है। रिपॉज़िटरी का README देखें.
रिमोट URL या आपकी मशीन पर कमांड? दोनों इंस्टॉल में क्या अंतर है
PlugMCP पर चलाएँ
A new server you create. It is not this listing's official endpoint. Use the publisher install when you want their URL and their credentials.
लॉन्चपब्लिशर से
Turn your Android phone into an MCP (Model Context Protocol) server. AI agents and desktop scripts can call your phone for live data and actions over LAN or Tailscale.
Turn your Android phone into an MCP (Model Context Protocol) server. AI agents and desktop scripts can call your phone for live data and actions over LAN.
Tab switching, staggered content reveals, log filters, the sliding segmented control, category chips, and dark mode — captured from the live UI:
PocketMCP-debug.apk (v1.0.0-beta.9) — install over USB with adb install -r PocketMCP-debug.apkPocketMCP is fully open-source and core functionality is free. The project is MIT-licensed and community contributions are welcome.
High-value use cases for all users:
PocketMCP uses a custom-built Jetpack Compose UI with a clean, platform-native design language — neutral surfaces, a single system-blue accent, and real typography.
#007AFF light / #0A84FF dark); semantic colors are reserved for status (green = running, orange = attention, red = destructive)A static HTML replica of all four screens (with a live light/dark toggle) lives in preview/app-preview.html — open it in any browser to see the design without building the app. The screenshots and demo video in this README are generated from it with node preview/capture.mjs both (headless Chrome + ffmpeg).
GET / and GET /health), including the WebSocket and SSE handshakes.X-API-Key, Authorization: Bearer <key>, or ?key=<key> (query parameter, for WebSocket/SSE clients that cannot set headers).EncryptedSharedPreferences.http_request.scripts/setup-wireless-adb.ps1 once — it grants WRITE_SECURE_SETTINGS and enables the service; afterwards the app toggles it itself, with no OEM screen involved.START, STOP, QUERY_STATUS).PocketMCP now includes a new high-level orchestration tool, intelligent_action, designed for "humanoid" multi-step flows across apps.
app/src/main/java/com/pocketmcp/tools/IntelligentActionTool.ktapp/src/main/java/com/pocketmcp/agent/
model/ intent/step/result modelsnlu/ parser and entity resolutionplanner/ graph builder and policy gateexecution/ orchestrator, executor, verifier, retry behaviorskills/ app-specific skill packs (youtube, x)perception/ popup/blocker helpersmemory/ session context and trace writingdialog/ clarification prompts for ambiguous requestsdry_run=true to inspect parsed intents and planned steps before execution.confirm_risky=true for safer defaults in production-like usage.agent-traces) for tuning.{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "intelligent_action",
"arguments": {
"command": "open youtube and search psg and bayern",
"dry_run": false,
"confirm_risky": true
}
}
}
Option A: install from pre-release APK
PocketMCP-debug.apk from v1.0.0-beta.1adb install -r PocketMCP-debug.apk
Option B: build from source and install
./gradlew assembleDebug
adb install app/build/outputs/apk/debug/app-debug.apk
8080) in the Configuration card.Required for full functionality:
ACCESS_FINE_LOCATION — used by get_locationREAD_CONTACTS — used by search_contactsCAMERACALL_PHONE permission in app settingsRECORD_AUDIO permission in app settingsSEND_SMS, READ_SMS permissionsREAD_MEDIA_AUDIO (Android 13+) or READ_EXTERNAL_STORAGE — used by audio transcriptionAll permission states are visible in the Settings tab with one-tap navigation to system settings.
# health
curl http://192.0.2.100:8080/health
# list tools
curl -X POST http://192.0.2.100:8080/mcp \
-H "Content-Type: application/json" \
-H "X-API-Key: your-api-key" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'
Or verify everything in one shot (health, auth, protocol, tool list):
node mcp-bridge/setup.mjs doctor --url http://192.0.2.100:8080/mcp --api-key your-api-key
Some One UI builds (Samsung Auto Blocker) refuse the accessibility toggle. One-time fix — pair wireless debugging, then run:
powershell -ExecutionPolicy Bypass -File .\scripts\setup-wireless-adb.ps1
The script grants WRITE_SECURE_SETTINGS, enables the accessibility service and the notification listener. Afterwards Settings shows a live toggle, and the accessibility_control MCP tool can enable/disable the service remotely.
If PocketMCP runs inside an Android emulator, do not use 10.0.2.15 from your host MCP client config.
Use ADB port forwarding and localhost:
powershell -ExecutionPolicy Bypass -File .\scripts\setup-emulator-mcp.ps1
Then set MCP URL to:
http://127.0.0.1:8080/mcp
Notes:
10.0.2.15 is emulator-internal (not host-reachable).10.0.2.2 is for emulator -> host, not host -> emulator.PocketMCP speaks Streamable HTTP natively (no companion process needed) and also ships a zero-dependency stdio bridge for tools that only launch local MCP servers. Both paths expose the same tools — use either, or both.
One command does the whole setup (Node 20+, no npm install):
node mcp-bridge/setup.mjs
It finds your phone on the LAN (mDNS), verifies health + API key + tool discovery, saves the connection to ~/.pocketmcp.json, and writes ready-made configs for the tools you pick:
Handy commands:
node mcp-bridge/setup.mjs doctor # end-to-end connectivity check
node mcp-bridge/setup.mjs doctor --call device_info # ...and actually run a tool
node mcp-bridge/setup.mjs print opencode # print one config, write nothing
node mcp-bridge/setup.mjs --mode bridge # configure the stdio bridge instead
node mcp-bridge/setup.mjs --mode both # write the HTTP config + print the bridge variant
Full per-tool walkthrough with every snippet: docs/harness-setup.md.
The phone endpoint is the core of the server and stays available either way — the bridge is just a proxy to it:
POST http://<phone-ip>:8080/mcp # JSON-RPC (JSON or SSE response)
GET http://<phone-ip>:8080/mcp # SSE stream
GET http://<phone-ip>:8080/health # public health check (no key)
WS ws://<phone-ip>:8080/ws # WebSocket transport (pass ?key=<api-key>)
Minimal client config (also in mcp-config.example.json):
{
"mcpServers": {
"pocketmcp": {
"type": "http",
"url": "http://192.0.2.100:8080/mcp",
"headers": {
"X-API-Key": "your-api-key"
}
}
}
}
Claude Code requires
"type": "http"; Cursor ignores the type field; OpenCode usesmcp.serversinstead ofmcpServers—setup.mjs print opencodeemits the right shape.
mcp-bridge/bridge.mjs is a single file with zero dependencies — no npm install:
node mcp-bridge/bridge.mjs --url http://192.0.2.100:8080/mcp --api-key your-api-key
After running the setup wizard once, the bridge auto-resolves your phone from ~/.pocketmcp.json (falling back to LAN discovery), so node mcp-bridge/bridge.mjs alone is enough:
--url / POCKET_MCP_URL: phone MCP URL (ws:// URLs auto-convert; default falls back to 127.0.0.1:8080 for emulators)--api-key / POCKET_MCP_API_KEY: key sent as X-API-Key--timeout-ms / POCKET_MCP_TIMEOUT_MS: per-request timeout (default 30000)--tools-ttl-ms / POCKET_MCP_TOOLS_TTL_MS: tool-list cache TTL (default 30000)--no-tool-cache / POCKET_MCP_DISABLE_TOOL_CACHE=1: always fetch the live tool list--verbose / POCKET_MCP_VERBOSE=1: detailed logs on stderrPOCKET_MCP_PROFILE: alternate profile path (default ~/.pocketmcp.json)from pocket_mcp_client import PocketMCPClient
phone = PocketMCPClient("http://192.0.2.100:8080", api_key="your-api-key")
print(phone.device_info())
print(phone.list_apps(limit=25))
print(phone.notifications("list", 10))
print(phone.human_command("vibrate my phone for 5 seconds"))
Python client now includes retries, typed exceptions, stricter argument validation, and a CLI:
# health check (default action)
python3 pocket_mcp_client.py 192.0.2.100:8080 your-api-key
# list tools
python3 pocket_mcp_client.py 192.0.2.100:8080 your-api-key --list-tools
# call one tool with JSON args
python3 pocket_mcp_client.py 192.0.2.100:8080 your-api-key \
--call send_message \
--args '{"app":"whatsapp","phone_number":"+15551234567","message":"hello from desktop"}'
scripts/pocket.mjs (Node 20+, zero dependencies) routes everyday phrases straight to tool calls — no AI in the loop, one HTTP request, typically a few hundred milliseconds on a warm LAN:
node scripts/pocket.mjs "torch on"
node scripts/pocket.mjs "torch on and open youtube" # chains: "and" / "then" / ";" / ","
node scripts/pocket.mjs "find my phone"
node scripts/pocket.mjs "call alex"
node scripts/pocket.mjs help # full phrase cheat sheet
node scripts/pocket.mjs --dry-run "lock the phone, torch on"
It reads the connection profile written by setup.mjs (~/.pocketmcp.json); anything it doesn't recognize is forwarded to the phone's on-device NLU (human_command) in the same round trip — still no desktop model involved.
app/src/main/java/com/pocketmcp/
├── MainActivity.kt # Compose entry point + business logic
├── accessibility/ # PhoneAccessibilityService
├── server/ # Ktor MCP server + JSON-RPC types
├── service/ # McpServerService (foreground service)
├── tools/ # ~35 MCP tool implementations
└── ui/ # Jetpack Compose UI
├── theme/ # Colors, Typography, Theme
├── components/ # Reusable UI components
│ ├── Cards.kt # Grouped cards, list rows, section headers
│ ├── CodeBlock.kt # Monospace code surface
│ ├── Controls.kt # Buttons, segmented control, search bar
│ └── NavBar.kt # Bottom tab bar
└── screens/ # Screen composables
├── DashboardScreen.kt
├── LogsScreen.kt
├── SettingsScreen.kt
└── ToolsScreen.kt
app/src/main/java/com/pocketmcp/tools/.McpToolHandler.McpServer.init { registry.register(YourTool()) }.ToolsScreen.kt for UI visibility.# Unit tests (JVM, no device required)
./gradlew testDebugUnitTest
# Debug build
./gradlew assembleDebug
Unit tests live in app/src/test/java/ and cover the API-key guard and throttling,
JSON-RPC encoding, tool result helpers, the shell safety filter, and the agent
NLU/planning layer. CI (.github/workflows/ci.yml) runs the build and the full test
suite on every push and pull request.
Some tools require Android special permissions or services:
CALL_PHONE)RECORD_AUDIO)SEND_SMS, READ_SMS, RECEIVE_SMS)ACCESS_FINE_LOCATION, ACCESS_COARSE_LOCATION)READ_CONTACTS)CAMERA)READ_MEDIA_AUDIO / READ_EXTERNAL_STORAGE)X-API-Key, Authorization: Bearer, or ?key= for WebSocket/SSE handshakes)EncryptedSharedPreferences)http_requestSTART, STOP, QUERY_STATUS)MIT
Turn your Android phone into an MCP (Model Context Protocol) server. AI agents and desktop scripts can call your phone for live data and actions over LAN.
टूल
अभी टूल सूची नहीं है। रिमोट सर्वर को पहले हेल्थ चेक के बाद सूची मिलती है।
FAQ
इस पेज पर Cursor, Claude Desktop, Claude Code या VS Code के लिए stdio कॉन्फ़िग कॉपी करें। यह पब्लिशर का इंस्टॉल इस्तेमाल करता है, PlugMCP प्रॉक्सी नहीं।
इस रिकॉर्ड में कोई ज़रूरी एनवायरनमेंट वेरिएबल दर्ज नहीं है।
PocketMCP stdio पर लोकल चलता है।
पिछली जाँच 2026-10-27 को हुई। Turn your Android phone into an MCP (Model Context Protocol) server. AI agents and desktop scripts can call your phone for live data and actions over LAN.