Spec Driven Development
MCP Server that facilitates spec-driven development workflows, not just Vibe Coding.
คำอธิบายจากผู้ทำ (ภาษาอังกฤษตามต้นฉบับ)
Android/KMM MCP server: logcat, ADB device control, Compose previews, network, Maestro flows.
สามเรื่องนี้ไม่รวมเป็นคะแนนเดียว เพราะความเห็น การวัด และความนิยม เป็นคนละเรื่องกัน
ตัวนี้ยังไม่ได้เรียบเรียงเป็นภาษาไทย ด้านล่างคือข้อเท็จจริงที่เราอ่านจาก registry
เลือกโปรแกรม AI ที่คุณใช้ แล้วคัดลอกค่าตั้งไปวาง
DEVILGE_ANDROID_PROJECT_ROOT, DEVILGE_OUTPUTS_ROOT, DEVILGE_DEFAULT_DEVICE_SERIAL, DEVILGE_FLOWS_ROOT, DEVILGE_MAESTRO_BIN_PATH, DEVILGE_ALLOW_FLOW_SCRIPTS, DEVILGE_HTTP_LOG_TAGS, DEVILGE_HTTP_LOG_FORMATต้องเตรียมก่อน
คุณใช้แอปไหน
เลือกแอปด้านบน เราจำไว้ให้ ครั้งหน้าปุ่มจะขึ้นว่า “ติดตั้งลง …”
เปิด Claude Desktop → Settings → Developer → Edit Config แล้ววางค่านี้ในไฟล์ claude_desktop_config.json
{
"mcpServers": {
"devilge": {
"command": "npx",
"args": [
"-y",
"devilge"
],
"env": {
"DEVILGE_ANDROID_PROJECT_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_OUTPUTS_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_DEFAULT_DEVICE_SERIAL": "ใส่ค่าของคุณ",
"DEVILGE_FLOWS_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_MAESTRO_BIN_PATH": "ใส่ค่าของคุณ",
"DEVILGE_ALLOW_FLOW_SCRIPTS": "ใส่ค่าของคุณ",
"DEVILGE_HTTP_LOG_TAGS": "ใส่ค่าของคุณ",
"DEVILGE_HTTP_LOG_FORMAT": "ใส่ค่าของคุณ"
}
}
}
}พิมพ์คำสั่งนี้ใน Terminal
claude mcp add devilge --env DEVILGE_ANDROID_PROJECT_ROOT='ใส่ค่าของคุณ' --env DEVILGE_OUTPUTS_ROOT='ใส่ค่าของคุณ' --env DEVILGE_DEFAULT_DEVICE_SERIAL='ใส่ค่าของคุณ' --env DEVILGE_FLOWS_ROOT='ใส่ค่าของคุณ' --env DEVILGE_MAESTRO_BIN_PATH='ใส่ค่าของคุณ' --env DEVILGE_ALLOW_FLOW_SCRIPTS='ใส่ค่าของคุณ' --env DEVILGE_HTTP_LOG_TAGS='ใส่ค่าของคุณ' --env DEVILGE_HTTP_LOG_FORMAT='ใส่ค่าของคุณ' -- npx -y devilgeเติมค่าที่เว้นว่างไว้ก่อนรัน
วางในไฟล์ .cursor/mcp.json ของโปรเจกต์ หรือ ~/.cursor/mcp.json
{
"mcpServers": {
"devilge": {
"command": "npx",
"args": [
"-y",
"devilge"
],
"env": {
"DEVILGE_ANDROID_PROJECT_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_OUTPUTS_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_DEFAULT_DEVICE_SERIAL": "ใส่ค่าของคุณ",
"DEVILGE_FLOWS_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_MAESTRO_BIN_PATH": "ใส่ค่าของคุณ",
"DEVILGE_ALLOW_FLOW_SCRIPTS": "ใส่ค่าของคุณ",
"DEVILGE_HTTP_LOG_TAGS": "ใส่ค่าของคุณ",
"DEVILGE_HTTP_LOG_FORMAT": "ใส่ค่าของคุณ"
}
}
}
}เบราว์เซอร์จะถามก่อนเปิดแอป จากนั้นแอปแสดงค่าตั้งให้ตรวจแล้วกดยืนยัน ช่อง key เว้นว่างไว้ให้คุณใส่เอง
วางในไฟล์ .vscode/mcp.json ของโปรเจกต์
{
"servers": {
"devilge": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"devilge"
],
"env": {
"DEVILGE_ANDROID_PROJECT_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_OUTPUTS_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_DEFAULT_DEVICE_SERIAL": "ใส่ค่าของคุณ",
"DEVILGE_FLOWS_ROOT": "ใส่ค่าของคุณ",
"DEVILGE_MAESTRO_BIN_PATH": "ใส่ค่าของคุณ",
"DEVILGE_ALLOW_FLOW_SCRIPTS": "ใส่ค่าของคุณ",
"DEVILGE_HTTP_LOG_TAGS": "ใส่ค่าของคุณ",
"DEVILGE_HTTP_LOG_FORMAT": "ใส่ค่าของคุณ"
}
}
}
}เบราว์เซอร์จะถามก่อนเปิดแอป จากนั้นแอปแสดงค่าตั้งให้ตรวจแล้วกดยืนยัน ช่อง key เว้นว่างไว้ให้คุณใส่เอง
ตัวนี้รันในเครื่องคุณ แต่ ChatGPT ต่อได้เฉพาะ server บนอินเทอร์เน็ต ลองเลือกแอปอื่น
ตัวเลือกเก็บในคุกกี้บนเครื่องนี้ ไม่ต้องมีบัญชี
DEVILGE_OUTPUTS_ROOT envDEVILGE_DEFAULT_DEVICE_SERIAL envDEVILGE_FLOWS_ROOT envDEVILGE_MAESTRO_BIN_PATH envDEVILGE_ALLOW_FLOW_SCRIPTS envDEVILGE_HTTP_LOG_TAGS envDEVILGE_HTTP_LOG_FORMAT envค่าตั้งนี้สร้างจากข้อมูลใน registry ของผู้ทำ ถ้าไม่ตรงกับ README ให้เชื่อ README
รันในเครื่องคุณ รายการเครื่องมือจะขึ้นในแอป AI หลังติดตั้ง
เราตรวจจากข้อมูลที่ใครก็เปิดดูได้ ยังไม่ได้อ่านโค้ด ข้อที่ไม่เกี่ยวกับตัวนี้ไม่นับในตัวหาร · ตรวจเมื่อ 6 พ.ย. 2569
ชื่อใน registry ยืนยันด้วยบัญชี GitHub Yercko ซึ่งเป็นเจ้าของ repo
ยังไม่ได้อ่านข้อมูล repo จาก GitHub
ยังไม่ได้อ่านข้อมูล repo จาก GitHub
ตัวนี้รันบนเครื่องคุณ ไม่มี endpoint บนอินเทอร์เน็ต
ตัวนี้รันบนเครื่อง ใช้ค่าที่ตั้งในเครื่องแทน
รันในเครื่องคุณ เราอ่านรายการเครื่องมือได้เฉพาะตัวที่มี endpoint บนอินเทอร์เน็ต
เทียบกับทุก server ที่ยังใช้งานในหมวดนี้ทั้งทะเบียน ดาวนับเฉพาะเมื่อผู้ลงทะเบียนเป็นเจ้าของ repo
จากการตรวจเบื้องต้นของเรา ผ่าน 1 จาก 1 ข้อที่ตรวจได้ เรายังไม่ได้อ่านโค้ด ก่อนใส่กุญแจหรือ token ให้ดูว่า server ขอสิทธิ์อะไร และเลือกกุญแจที่ทำได้เท่าที่จำเป็น
ต้องใส่ค่าเหล่านี้: DEVILGE_ANDROID_PROJECT_ROOT
รันบนเครื่องของคุณ โปรแกรม AI จะเปิด server ขึ้นมาเองเมื่อใช้ ข้อมูลไม่ต้องผ่านเซิร์ฟเวอร์ของผู้ทำ (ยกเว้นตัวที่ไปเรียกบริการออนไลน์ต่อ)
repo บน GitHub มีการแก้โค้ดล่าสุด – และส่งรุ่นล่าสุด (0.2.3) เข้า registry 6 เดือนที่ผ่านมา
โปรแกรมที่รองรับ MCP เช่น Claude Desktop, Claude Code, Cursor และ VS Code ตัวนี้ต้องมี Node.js ในเครื่องด้วย
ในหมวดเดียวกันมี Spec Driven Development, Remote Desktop Commander, debuff
server หมวดเดียวกันจากผู้ทำคนอื่น เรียงตามดาว
อ่านการ์ด:★ ดาว GitHubiสามเสา: รีวิว · ผลตรวจ · การใช้งานiอัปเดต = วันที่ส่งรุ่นล่าสุดเข้า registryi
MCP Server that facilitates spec-driven development workflows, not just Vibe Coding.
Remote Desktop Commander: use files, terminal and processes on your own computers from any AI app.
Let coding agents play, test and tune your 2D web game: live state, explained errors, replays, fuzz.
ส่วนนี้คัดจาก repo ของผู้ทำตามต้นฉบับ PopNx MCP ไม่ได้ตรวจหรือรับรองเนื้อหา ตัด HTML รูปภาพ และสคริปต์ออกแล้ว ลิงก์จะพาออกนอกเว็บ
Model Context Protocol (MCP) server that lets an AI assistant — typically Claude — develop, drive, and observe an Android / KMM app end-to-end.
devilge exposes 33 tools that cover the full inner loop: read the project, build it, install it, launch it, drive its UI, capture errors and network traffic, run tests. Anything an LLM coding agent would otherwise have to ask the user to do manually.
| Category | Tools | Purpose |
|---|---|---|
| Device read (8) | list_devices, get_logcat, get_app_errors, inspect_packages, resize_logcat_buffer, get_network_calls, get_compose_preview_source, list_compose_previews | Observe device + project state |
| Project static (3) | get_project_structure, get_compose_previews_tree, run_gradle_task (the latter wraps build-result parsers for kotlinc/javac/ksp errors, JUnit XML, Lint XML) | Inspect Gradle/KMM project + run any Gradle task |
| Device drive (7) | take_screenshot, dump_ui, input_tap, input_text, input_key, input_swipe, set_input_visualization | Manipulate the running app |
| Locators + waits (6) | tap_text, tap_resource_id, set_text, wait_for_text, wait_for_resource_id, wait_for_idle | Semantic UI navigation, no coordinate magic |
| Lifecycle (5) | launch_app, force_stop_app, clear_app_data, install_apk, run_instrumented_tests | Cold-start app, run Espresso tests, fast install |
| Maestro flows (optional) (3) | run_maestro_flow, list_maestro_flows, validate_maestro_flow | Reusable YAML flows for recurring navigation |
| Composition (1) | batch | Chain multiple devilge tools in one round trip |
215 unit tests in Vitest, all green. Strict TypeScript (strict, noUncheckedIndexedAccess).
Hosts that confirm every tool call (Claude Desktop, Cowork) can become noisy when the agent walks through multi-step UI flows. devilge_batch collapses a sequence into a single MCP call so the user approves once for the whole sequence.
// Tap "Settings", wait, screenshot, tap a row, screenshot — one approval.
{ "actions": [ { "name": "devilge_tap_text", "input": { "text": "Settings" } }, { "name": "devilge_wait_for_idle", "input": { "timeoutMs": 5000 } }, { "name": "devilge_take_screenshot" }, { "name": "devilge_tap_text", "input": { "text": "Wallpaper & style" } }, { "name": "devilge_take_screenshot" } ] }
Rules: capped at 20 actions per call; cannot be nested; cannot include destructive tools (devilge_clear_app_data, devilge_install_apk) — those always require their own dedicated prompt; stops on the first error and reports which step failed.
All tools also expose MCP annotations (readOnlyHint, idempotentHint, destructiveHint, openWorldHint). Hosts that respect annotations can auto-approve safe reads and prompt only on state-changing tools.
Clean / hexagonal layering, every concern replaceable in isolation:
src/
├── config/ # Config loading, structured logger, typed errors ├── domain/ │ ├── entities/ # Pure data types │ └── ports/ # Interfaces the application talks to ├── application/ # Use cases — orchestrate ports, no IO of their own ├── infrastructure/ │ ├── adb/ # AdbAdapter, AdbAppController, runners, parsers │ ├── build/ # Gradle adapter + parsers (compile errors, JUnit, Lint) │ ├── maestro/ # Optional Maestro adapter + YAML validator │ ├── network/ # Ktor logcat parser + header sanitizer │ ├── scanners/ # ComposePreviewScanner, ProjectScanner, FileWalker │ └── security/ # PathValidator, CommandSanitizer └── presentation/ └── tools/ # MCP tool definitions (Zod schemas + handlers)
src/server.ts is the *composition root*: it constructs every concrete dependency and wires them into an McpServer. Nothing else in the codebase performs construction.
devilge runs on a developer's machine, exposes mutating tools to an LLM, and shells out to ADB and (optionally) Gradle / Maestro. It assumes the operator connects only to a dev emulator or wiped test device, never a personal device with logged-in apps.
DEVILGE_ANDROID_PROJECT_ROOT or the configured outputs / flows roots. Any escape throws SecurityError.adb, gradlew, maestro) is spawned with shell: false and an argv array. Arguments are never concatenated into strings.CommandSanitizer regex allowlists before reaching argv.DevilgeError subclasses surface their messages. Unexpected exceptions become an opaque INTERNAL_ERROR.Authorization, Cookie, Set-Cookie, X-API-Key and other well-known sensitive headers are redacted from get_network_calls output.runScript: blocks (which execute JS) are rejected unless the operator explicitly sets DEVILGE_ALLOW_FLOW_SCRIPTS=true.The MVP does include write tools (input automation, app install, data wipe, force-stop). These are gated to a dev-only device by operator policy, not by server logic.
cd devilge
npm install cp .env.example .env
npm run build
Run the tests:
npm test
Verify the build:
npm run typecheck # static type-check (no emit)
npm run build # emit dist/ npm run lint # eslint
Add an entry to your claude_desktop_config.json (path varies by OS):
{
"mcpServers": { "devilge": { "command": "node", "args": ["/absolute/path/to/devilge/dist/index.js"], "env": { "DEVILGE_ANDROID_PROJECT_ROOT": "/absolute/path/to/your/android/project", "DEVILGE_KTOR_LOG_TAG": "HttpClient" } } } }
Restart Claude Desktop. The 33 tools should appear in the tool picker.
DEVILGE_ANDROID_PROJECT_ROOT=/absolute/path/to/your/android/project \
DEVILGE_KTOR_LOG_TAG=HttpClient \ npx --yes @modelcontextprotocol/inspector \ node dist/index.js
| Variable | Required | Default | Description |
|---|---|---|---|
DEVILGE_ANDROID_PROJECT_ROOT | ✅ | — | Absolute path to the Android/KMM project. All file reads are sandboxed under this directory. |
DEVILGE_ADB_PATH | adb (from PATH) | Absolute path to the adb binary. Pinning is recommended. | |
DEVILGE_DEFAULT_DEVICE_SERIAL | — | Default serial used when a tool call omits it. Useful when several devices are attached. | |
DEVILGE_LOGCAT_MAX_LINES | 500 | Default cap for get_logcat. Hard upper bound: 5000. | |
DEVILGE_LOG_LEVEL | info | One of error, warn, info, debug. | |
DEVILGE_KTOR_LOG_TAG | HttpClient | Logcat tag the HTTP-client logger writes under. Use HttpClient for Ktor (default), OkHttp for Retrofit/OkHttp, or whatever your custom logger uses. | |
DEVILGE_HTTP_LOG_FORMAT | auto | Which parser(s) to apply. ktor, okhttp, or auto (tries both). | |
DEVILGE_OUTPUTS_ROOT | /.devilge-outputs/ | Where screenshots / UI dumps land. Add to .gitignore. | |
DEVILGE_FLOWS_ROOT | /devilge-flows/ | Where Maestro YAML flows live. | |
DEVILGE_MAESTRO_BIN_PATH | auto-detected from PATH | Absolute path to the maestro binary. Optional — Maestro tools degrade gracefully when missing. | |
DEVILGE_ALLOW_FLOW_SCRIPTS | false | Set to true to allow runScript: blocks inside Maestro YAML. Off for safety. |
Maestro is optional. Without it installed, every other devilge tool keeps working. The three flow tools (run_maestro_flow, list_maestro_flows, validate_maestro_flow) register unconditionally and return MAESTRO_NOT_INSTALLED when the binary isn't found.
To enable:
brew tap mobile-dev-inc/tap
brew install maestro
curl -Ls "https://get.maestro.mobile.dev" | bash
Restart the inspector. Flows go in /devilge-flows/ .yaml. Example:
appId: com.example.your.app
Then:
{
"name": "login_flow", "params": { "EMAIL": "user@example.com", "PASSWORD": "..." } }
MAESTRO_DISABLE_ANALYTICS=true is injected automatically. runScript: blocks are denied unless you opt in.
You can render @Preview Composables to PNG without launching the full app. devilge does NOT add a dedicated tool for this — the existing run_gradle_task plus the official Google plugin cover it cleanly, and adding a wrapper would make us depend on Gradle conventions that vary by project.
This is completely optional: if you don't add the plugin, devilge runs unchanged. You only lose this specific workflow.
To enable in your project, add to your Compose module's build.gradle.kts:
plugins {
// existing plugins... id("com.android.compose.screenshot") version "0.0.1-alpha10" }
android { experimentalProperties["android.experimental.enableScreenshotTest"] = true }
And in gradle/libs.versions.toml:
[plugins]
composeScreenshot = { id = "com.android.compose.screenshot", version = "0.0.1-alpha10" }
Once the plugin is in place, render previews from the LLM via the existing tool:
devilge_run_gradle_task {
"task": ":composeApp:validateDebugScreenshotTest" }
The PNGs land under composeApp/build/outputs/screenshotTest/.... Claude can then read them via its Read tool to verify visual output without installing the app.
1. run_gradle_task ":composeApp:assembleDebug" # build once at start
For recurring navigation paths (login, search, etc.), capture once as a Maestro flow and replay with one tool call.
ตัดมาแค่ช่วงต้น อ่านต่อใน repo