list_gradle_tasks
Fetch available Gradle tasks from an Android project's root or a specific submodule to discover build, test, and install targets for adb-mcp.
Instructions
List the available Gradle tasks in project_dir (gradlew tasks) — to discover build/test/install targets. In a multi-module build this lists the ROOT project's own tasks by default; pass task=":tasks" (e.g. ":app:tasks", from list_gradle_projects) to scope to a submodule instead.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| args | No | Extra arguments passed to Gradle (e.g. --stacktrace, -Pflavor=free). | |
| json | No | For run_unit_tests/run_instrumented_tests: return the test summary as structured JSON (per-suite timing, full failure stack traces) instead of the human-readable text summary. Ignored by gradle_build and list_gradle_tasks. | |
| task | No | Gradle task to run. Defaults to the tool's standard task. | |
| project_dir | No | Path to the Android project root containing the Gradle wrapper (gradlew). Optional if session_set_defaults has pinned a project_dir for this session. |