Android CLI
Android (Google)OfficialCreated by Google LLCDistributed by Android (Google)
- Skill
- Tool integration
- Software development
- Apache-2.0
- Medium risk
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
The android-cli skill provides essential instructions for utilizing the Android command-line tool. It covers the full lifecycle of Android development, including SDK management, project scaffolding from templates, application deployment, and device interaction. The skill also details how to perform UI inspection using layout dumps and screen captures, run automated journey tests, and access official Android documentation directly from the command line.
What it does
- Installs and configures the Android CLI environment.
- Manages Android SDK components, including installation, updates, and removal.
- Creates new Android projects from predefined templates.
- Inspects application UI via JSON layout trees and annotated screenshots.
- Executes and reports on automated journey tests for app behavior validation.
- Provides access to official Android developer documentation and API guidance.
When to use it
- When setting up a new Android development environment or managing SDK dependencies.
- When you need to automate project creation or build processes.
- When performing UI testing or debugging layout issues on connected devices or emulators.
- When running automated test suites or journey tests to verify app functionality.
- When you need quick access to official Android API documentation or migration guides.
Advantages
- Centralizes essential Android development tasks into a single CLI tool.
- Enables programmatic UI inspection and interaction for automated testing.
- Provides a structured approach to running and reporting on journey tests.
- Simplifies SDK and environment management through clear command-line interfaces.
Usage examples
- “Create a new Android project named 'My App' using the empty-activity template.”
- The CLI generates a new project structure in the specified directory using the empty-activity template.
- “Inspect the current UI layout of the connected Android device.”
- The tool returns a JSON tree of UI elements, including their bounds, resource IDs, and interaction states.
- “Install the Android SDK platform for API level 34.”
- The CLI downloads and configures the specified SDK package in the local environment.
- “Search for documentation on how to use Android WorkManager.”
- The CLI retrieves relevant articles and examples from the official Android Knowledge Base.
Install
Download the skill as a ZIP:
https://autogineer.com/agent-skills/android/android-cli/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip android-cli.zip -d .agents/skills
Documentation by Google LLC
This skill provides instructions for using the android CLI tool. The tool
includes various commands for creating projects, running applications,
interacting with devices, and managing the CLI environment.
Installation
If the android tool is not in the path, install it. To install run the following command:
Linux x86-64: curl -fsSL https://dl.google.com/android/cli/latest/linux_x86_64/install.sh | bash
Linux ARM64: curl -fsSL https://dl.google.com/android/cli/latest/linux_arm64/install.sh | bash
Mac Arm: curl -fsSL https://dl.google.com/android/cli/latest/darwin_arm64/install.sh | bash
Mac Intel: curl -fsSL https://dl.google.com/android/cli/latest/darwin_x86_64/install.sh | bash
Windows: curl -fsSL https://dl.google.com/android/cli/latest/windows_x86_64/install.cmd -o "%TEMP%\i.cmd" && "%TEMP%\i.cmd"
SDK management
To manage the installation of Android SDKs and tools, use the sdk command.
For example:
android sdk install <package>[@<version>]...: Install specific packages. Multiple packages can be specified, separated by spaces.<version>defaults to latest. For example:android sdk install platforms/android-30@2 platforms/android-34android sdk update [<pkg-name>]: Update a specific package or all packages to the latest version.android sdk remove <pkg-name>: Remove a package from the local SDK.android sdk list --all: List installed and available SDK packages.
Project creation
Create projects from templates using the create command.
For example: android create empty-activity --name="My App" --output=./my-app
Interacting with Android devices
Use the android layout command to inspect the UI layout of an Android
application in JSON format. Use the android screen command to visually inspect
the UI and obtain bounding coordinates for visual regions.
android layout dumps the UI as JSON. android screen capture -o <file path> saves a PNG.
Both auto-select the device when only one is connected; with more than one, pass --device=<serial> (use adb devices to list serials).
UI Dump
android layout returns a JSON tree of the UI elements on screen.
Each JSON object represents a UI element in the Android app. The following properties may be present:
text- any literal text the element containsresource-id- the Android resource id used to refer to the elementcontent-desc- a description of a UI element for use by accessibility toolsinteractions- the set of user interactions the element supports. May contain one or more of:CHECKABLE,CLICKABLE,FOCUSABLE,SCROLLABLE,LONG-CLICKABLE,PASSWORDstate- the set of states the element is in. May contain one or more ofCHECKED,FOCUSED,SELECTEDbounds- the screen coordinates of the bounding rectangle of the element, in the format[min X,min Y][max X, max Y]center- the screen coordinates of the center of the element, in the format[x,y]off-screen- if true, the element is in the UI hierarchy but not within the bounds of the screen; it may require scrolling to view.hidden- if true, the element is in the UI hierarchy but not visible or interactive on screen.
Use layout as a primary means of examining an Android app.
By default, layout only returns elements that have content or are interactive:
elements with non-empty
textorcontent-descpropertieselements with non-empty
interactionsorstateTo return all elements, use the--fullflag
If layout continues to fail, use android screen capture --annotate to inspect the app.
Screenshot
android screen capture -o <file path> (or --output=<file path>) saves a PNG of the current device screen to <file path>.
Use screen capture as a secondary means of examining an Android app
Examples:
Understanding the content of an on-screen image
Looking at a
WebView(web content does not always appear in the ui dump)Trying to find a UI element by its visual appearance
IMPORTANT : Always VISUALLY examine the PNG image returned from any android screen command BEFORE doing anything else.
Annotated Screenshot
android screen capture --annotate -o <file path> (or -a -o <file path>)
android screen resolve --screenshot <path> --string <string>
The --annotate command adds numerical labels and bounding boxes around UI elements. Use this command to locate UI elements that cannot
be located in the layout output.
To refer to these labels in input commands, use screen resolve to convert labels into coordinates:
android screen resolve --screenshot <file path> --string "#3" returns <x coord of region 3> <y coord of region 3>
To save turns, you can combine shell commands:
adb shell input $(android screen resolve --screenshot screen.png --string "tap #34")
This command taps on region #34 from screen.png
Input
Use adb shell input for interacting with Android devices.
Refer to the "interactions" property of an element for what interactions can be performed on a particular element.
Interact with UI elements with their center coordinate or their bounds coordinates:
json { "key": -248568265, "class": "android.widget.Button", "bounds": "[138,9][167,38]", "center": "[152,23]" }
To tap on this button, you would execute adb shell input tap 152 23. This taps the center.
{
"key": 12487234,
"class": "com.example.ui.ScrollableList",
"bounds": "[100,200][400,600]",
"center": "[250,400]"
}To scroll down on this list, you would execute adb shell input swipe 250 400 250 200 500. This swipes from the center to the top over 500ms.
Text Input
To enter text, ensure the field is focused and execute adb shell input text "<text>".
Spaces (
%s): Replace spaces with%s(Android ignores text after raw spaces):adb shell input text "Hello%sworld"(enters"Hello world").Special characters: Escape shell metacharacters (
&,$,(,),!):adb shell input text "AT\&T"oradb shell input text 'Price:\$10'.Submit / Enter:
adb shell input keyevent 66
Android Interaction Rules
Always ensure text input fields have
"FOCUSED"in their"state"list before entering text.If an element has
"SCROLLABLE"in its"interactions"list, try scrolling it when looking for missing UI elements.Always scroll slowly when executing scroll inputs. The 5th argument to
adb shell input swipecontrols scroll duration.Content may take time to load; if a
layoutis missing information after you take an action, wait a few seconds, then performlayoutagain to see if anything changes.
Running journey tests
Journey tests involve device interaction; use the android layout and android screen commands to evaluate Journeys. The instructions for device interaction
apply here as well.
A journey is an XML-specified test of an Android app's behavior. It consists of a list of <action> elements. For example:
xml <journey name="My Journey"> <description> A sample journey to illustrate the format </description> <actions> <action> Tap the "Home" icon </action> <action> Verify that the app is on its Home screen </action> </actions> </journey>
Evaluate a journey by proceeding through the <actions> list in sequential order. Evaluate each <action> block individually.
A journey succeeds if all elements in the <actions> list succeed.
A journey is a test case for an app. The journey XML is the source of truth; if the app disagrees with the journey, the app has failed. Additionally, if the app exits, crashes, or freezes, journey evaluation stops and the journey fails.
IMPORTANT - Execute each step EXACTLY as written, and independently of other steps! If an action says to "tap the first search result",
you MUST find the search results and tap the first one. Do this even if you believe you know the intent behind the action.
Taking Actions
Some <action> elements specify UI interactions to perform on the running Android app. Perform the interaction and verify that the app does
not crash or behave in an unexpected manner. This is the only verification you should perform for an <action>.
If the interaction cannot be performed as specified, the journey fails.
Example:
<action>Click the red button</action>
If you determine a red button is not present in the UI, the journey fails.
If the text of an <action> specifies a list of actions, break it into sub-actions and evaluate them individually:
Example:
<action>Search for soda and add the first result to the cart</action>
This should be evaluated as:
<action>Search for soda</action> <action>Add the first result to the cart</action>
If an <action> contains something that is not a specification for a UI interaction, alert the user that the journey is malformed and exit
early, specifying the error in question.
Verifying Expectations
<action> elements that begin with "check" or "verify" specify expectations for the current state of the Android app. Determine the current
state of the app and check if the expectations are met.
Determine the current state of the app by inspecting the current screen of the device without interacting with it.
Example:
<action>Check if "Switch 2" is visible on the screen</action>
This requires only inspecting the current screen, not scrolling or interacting. If "Switch 2" is not currently visible, the action fails.
If the expectations are not met, mark the <action> as a failure and the journey evaluation ends. A single <action> may contain
multiple expectations.
Example:
<action>Verify that the app is on the Home screen, the Home icon is blue, and the temperature is displayed</action>
This <action> fails if ANY of the following are false:
The app is on the Home screen
There is a Home icon, and it is blue
A temperature is displayed
Handling failure
When running a journey, evaluate it as a test. Failure is acceptable, and often expected. Proper reporting of failures is the priority.
Keep debugging and troubleshooting to a minimum; assume that tools are showing you the correct output every time. The goal is to determine if the current Android app can correctly handle the current steps outlined in the journey. Suggestions for bug fixes, clarification, or other improvements should be kept to journey evaluation summary at the end.
Summarizing
After evaluating the whole journey, output a markdown (.md) file describing the results.
The file should have the following format:
# Journey: <Name of the journey>
## Results
<!-- Append "✅" to the action header if the instruction was evaluated or "❌" if the instruction could not be evaluated -->
### Action: Click the blue button ✅
- **Commands**:
<!-- A list of the ADB commands executed while evaluating the instruction -->
- `adb shell input swipe 490 200 500 500 500`
- `adb shell input tap 45 920`
<!-- Failure reasons, feedback, or other useful information -->
- **Comment**: The journey step doesn't specify that the button requires scrolling to see
### Action: Check if "Switch 2" is visible on the screen ✅
- **Screenshot**: [switch_2_screenshot.png](path/to/screenshot)
- **Comment**: Confirmed both in layout and visually
### Action: The home screen is shown ❌
- **Comment**: The settings page was shown
<!-- Append nothing to the action header if the action was not evaluated because the journey execution ended early -->
### Action: Swipe down to view active notificationsDoc searching
The docs command searches authoritative, high-quality Android developer
documentation in the Android Knowledge Base. By providing a few keywords, this
tool will return high quality articles that contain examples or guidance on how
to use Android APIs or libraries. Use this tool to obtain additional information
on how to achieve Android-specific tasks or to know more about Android APIs,
surfaces, libraries, or devices.
Always use this tool to get the most up-to-date information about Android concepts. Typical good use cases are:
Finding migration guides for APIs.
Finding examples for APIs.
Finding up-to-date information about Android APIs.
Finding best practices for Android concepts.
Running APKs
Use the run command to run Android apps.
Managing emulators
Manage Android Virtual Devices (AVDs) using the android emulator command
Managing skills
Manage agent skills for Android using the android skills command.
Updating the CLI
Update the Android CLI using the android update command.
android help output
Usage: android [-Vhv] [--sdk=PARAM] [COMMAND]
-h, --help Shows the help message for the specified command
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
analyze Analyzes the file(s) (AAB, APK, JAR, AAR) at the given location(s)
and reports back all available details
auth Authentication commands. Log in to and out of Google services for
Android CLI
build Build android artifacts
completion Installs shell autocomplete configuration for Android CLI in the
current user profile
create Creates a new Android project from available templates. You can
specify the project name, output directory, `minSdk` value, and
dry-run execution
describe Analyzes an Android project to generate descriptive metadata. This
command identifies and outputs the paths to JSON files that detail
the project's structure, including build targets and their
corresponding output artifact locations (such as APKs). This
information enables other tools and commands to locate build
artifacts efficiently
device Manage Android devices. Mirror connected devices or emulators in a
desktop window and manage remote physical device reservations
docs Searches and fetches developer documentation from the official
Android Knowledge Base
emulator Manages Android Virtual Devices (AVDs). Includes commands to
start, stop, list, and view details about emulators
help Shows the help information for a specified command
info Prints environment information including SDK location and
configuration variables
init Initializes the environment for Android CLI. Sets up required
configurations, directories, and default skills
input Interact with Android apps by performing gestures and key events
on UI elements
install Installs an Android app (one or more APKs) on a connected device
or emulator without activating any components, using incremental
optimizations for faster deployment than `adb`
layout Returns the layout tree of an app
preview Renders Jetpack Compose @Preview functions to PNG images and
optionally exports component tree JSON files. Runs without a
device or an IDE
profiler Profiles Android apps, games, and devices
run Deploys and launches an Android app on a connected device or
emulator
screen Captures and inspects the screen of a connected Android device or
emulator
sdk Manages the Android SDK installation. Includes commands to
install, update, remove, and list available and installed SDK
packages
signals Queries app stability and field telemetry from Crashlytics
skills Manages Android CLI skills. Includes commands to install, remove,
list, and search for skills by keyword
studio Connects Android CLI to a running Android Studio instance to
analyze files, find declarations and usages, render Compose
previews, and look up library versions
update Updates Android CLI to the latest version
analyze
Usage: android analyze [-h] [--analysis=PARAM] [--format=PARAM] <path>
Analyzes the file(s) (AAB, APK, JAR, AAR) at the given location(s) and
reports back all available details
Options:
--analysis=PARAM Analysis category to filter output (basic,
optimization). Supports comma-separated values
(default: all)
-f, --format=PARAM Output format: json, textproto. If omitted,
output is formatted for human readability
-h, --help Shows the help message for the specified
command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Positional Parameters:
<path> Path to the target file(s) to analyze (AAB, APK, JAR, AAR)
auth
Usage: android auth [-h] [COMMAND]
Authentication commands. Log in to and out of Google services for
Android CLI
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
login Log in to Google services for Android CLI
logout Log out from Google services for Android CLI
status Prints the currently signed-in account
build
Usage: android build [-h] [<reference>] [-- <build_args>]
Build android artifacts
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Positional Parameters:
<reference> Build reference ([system://][path]?[target])
-- <build_args> Arguments passed verbatim to the build system. Use
-- to separate from other arguments
completion
Usage: android completion [-h] [<shell>]
Installs shell autocomplete configuration for Android CLI in the
current user profile
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Positional Parameters:
<shell> If provided, prints the completion configuration script for
the specified shell without installing it. Supports Bash
and Zsh
create
Usage: android create [-h] [--application-id=PARAM] [--force] [--list]
[--min-sdk=PARAM] [--name=PARAM] [--namespace=PARAM]
[--output=PARAM] [<template-name>]
Creates a new Android project from available templates. You can
specify the project name, output directory, `minSdk` value, and
dry-run execution
Options:
--application-id=PARAM The app ID for the app, for example
`com.example.myapp`
--force Allow creating the project in a
non-empty directory, overwriting
existing files
-h, --help Shows the help message for the specified
command
--list List all available templates
--min-sdk=PARAM The `minSdk` value supported by the app
(the default value is defined in the
template)
--name=PARAM The name of the app, for example `My
Application`
--namespace=PARAM The namespace for resources and package
name for Kotlin source files
-o, --output=PARAM The destination project directory path
(the default value is `.`)
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for
troubleshooting
-V, --version Print version information and exit
Positional Parameters:
<template-name> The template name
describe
Usage: android describe [-h] [--project_dir=PARAM]
Analyzes an Android project to generate descriptive metadata. This
command identifies and outputs the paths to JSON files that detail the
project's structure, including build targets and their corresponding
output artifact locations (such as APKs). This information enables
other tools and commands to locate build artifacts efficiently
Options:
-h, --help Shows the help message for the specified
command
--project_dir=PARAM The project directory to describe
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
device
Usage: android device [-h] [COMMAND]
Manage Android devices. Mirror connected devices or emulators in a
desktop window and manage remote physical device reservations
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
hub Launches a desktop window for real-time screen mirroring and
interactive control of a connected Android device or
emulator
remote Manage remote physical devices. Includes commands to list,
reserve, connect to, and manage remote device reservations
docs
Usage: android docs [-h] [COMMAND]
Searches and fetches developer documentation from the official Android
Knowledge Base
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
fetch Fetches an Android documentation article from a URL starting
with `kb://`
search Searches Android documentation. Enclose keywords in quotes
emulator
Usage: android emulator [-h] [COMMAND]
Manages Android Virtual Devices (AVDs). Includes commands to start,
stop, list, and view details about emulators
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
create Creates a virtual device
list Lists available virtual devices
remove Deletes a virtual device
start Launches the specified virtual device. This command returns
when the emulator is fully started and ready to use
stop Stops the specified virtual device
help
Usage: android help [-h] [COMMAND]
Shows the help information for a specified command
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Positional Parameters:
COMMAND The command to show help for
info
Usage: android info [-h] [<field>]
Prints environment information including SDK location and
configuration variables
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Positional Parameters:
<field> The specific field to print the value of (sdk, version,
launcher_version). If omitted, prints all fields
init
Usage: android init [-h]
Initializes the environment for Android CLI. Sets up required
configurations, directories, and default skills
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
input
Usage: android input [-h] [--device=PARAM] [COMMAND]
Interact with Android apps by performing gestures and key events on UI
elements
Options:
--device=PARAM Device serial number or emulator ID (as reported
by 'adb devices')
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
key Press a hardware button, navigation key, or Android keycode
scroll Scroll a container element, optionally until a target
element appears
swipe Swipe from a UI element matching a selector in a given
direction
tap Tap on a UI element matching a selector
text Type text into a UI element matching a selector
install
Usage: android install [-h] [--apks=PARAM] [--device=PARAM] [--install-options=PARAM]
[--use-delta-install] [<apks_or_reference>] [--
<build_args>]
Installs an Android app (one or more APKs) on a connected device or
emulator without activating any components, using incremental
optimizations for faster deployment than `adb`
Options:
--apks=PARAM The paths to the APKs, comma separated
--device=PARAM The device serial number
-h, --help Shows the help message for the
specified command
--install-options=PARAM Additional options or flags to pass to
package manager install (for example,
`-g`, `-d`)
--use-delta-install Use fast delta install (speeds up
incremental updates by transferring
only modified code and resources;
default: `true`)
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for
troubleshooting
-V, --version Print version information and exit
Positional Parameters:
<apks_or_reference> APK file path(s) or a build reference
([system://][path]?[target])
-- <build_args> Arguments passed verbatim to the build system.
Use -- to separate from other arguments
layout
Usage: android layout [-dhp] [--device=PARAM] [--flat] [--full] [--no-idle]
[--output=PARAM]
Returns the layout tree of an app
Options:
--device=PARAM The device serial number
-d, --diff Deprecated; no-op flag. Will be removed in a
future release
--flat Returns a flat list instead of a tree
--full Returns the full tree, including non-interactive
and hidden elements
-h, --help Shows the help message for the specified command
--no-idle Don't wait for layout idle state when fetching
layout
-o, --output=PARAM Writes the layout to the specified file or
directory. If omitted, prints to standard output
-p, --pretty Pretty-prints the returned JSON
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
preview
Usage: android preview [-h] [COMMAND]
Renders Jetpack Compose @Preview functions to PNG images and
optionally exports component tree JSON files. Runs without a device or
an IDE
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
list Lists available Jetpack Compose @Preview functions in a
target
render Builds a target and renders its Jetpack Compose @Preview
functions to PNG images and optional component tree JSON
files
profiler
Usage: android profiler [-h] [COMMAND]
Profiles Android apps, games, and devices
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
heapdump Capture Android JVM heap dump snapshots (requires API
29+)
session Manage profiling sessions of any type: list them, query
their status, or terminate them
systemtrace System tracing tools. Captures CPU scheduling, thread
slices, frame lifecycle, GPU counters, and Vulkan
timing into a Perfetto trace file
run
Usage: android run [-h] [--activity=PARAM] [--apks=PARAM] [--debug] [--device=PARAM]
[--install-options=PARAM] [--type=PARAM] [--use-delta-install]
[<apks_or_reference>] [-- <build_args>]
Deploys and launches an Android app on a connected device or emulator
Options:
--activity=PARAM The activity name
--apks=PARAM The paths to the APKs, comma separated
--debug Run in debug mode
--device=PARAM The device serial number
-h, --help Shows the help message for the
specified command
--install-options=PARAM Additional options or flags to pass to
package manager install (for example,
`-g`, `-d`)
--type=PARAM The component type (`ACTIVITY`,
`WATCH_FACE`, `TILE`, `COMPLICATION`,
`DECLARATIVE_WATCH_FACE`,
`WEAR_WIDGET`)
--use-delta-install Use fast delta install (speeds up
incremental updates by transferring
only modified code and resources;
default: `true`)
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for
troubleshooting
-V, --version Print version information and exit
Positional Parameters:
<apks_or_reference> APK file path(s) or a build reference
([system://][path]?[target])
-- <build_args> Arguments passed verbatim to the build system.
Use -- to separate from other arguments
screen
Usage: android screen [-h] [COMMAND]
Captures and inspects the screen of a connected Android device or
emulator
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
capture Outputs the device screen to a PNG
resolve Targets UI elements visually. Substitutes bounding box
coordinates from an annotated screenshot into a string,
replacing all instances of `#N` with the center coordinates
of the bounding box labeled `N`
sdk
Usage: android sdk [-h] [--ignore-outdated-xmls] [--platform=PARAM]
[COMMAND]
Manages the Android SDK installation. Includes commands to install,
update, remove, and list available and installed SDK packages
Options:
-h, --help Shows the help message for the specified
command
--ignore-outdated-xmls When installing or updating packages, do
not update other packages' XML files
--platform=PARAM Target platform `<os>_<arch>` (for
example, `linux_x86_64`, `mac_arm64`, or
`windows_x86`); defaults to the current
host
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for
troubleshooting
-V, --version Print version information and exit
Commands:
install Installs SDK packages
list Lists installed and available SDK packages
remove Removes packages from the SDK
update Updates one or all packages to the latest version
signals
Usage: android signals [-h] [COMMAND]
Queries app stability and field telemetry from Crashlytics
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
context Lists accessible Crashlytics projects and apps
crashes Lists, describes, and analyzes field-reported crash, ANR,
and non-fatal issues
heaps Lists, describes, and downloads heap dumps collected on
low-memory events
skills
Usage: android skills [-h] [COMMAND]
Manages Android CLI skills. Includes commands to install, remove,
list, and search for skills by keyword
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
add Installs a specific skill by its ID to your environment
find Searches for available skills in the repository matching a
keyword
list Lists installed and available skills
remove Removes an installed skill by its ID
update Updates installed skills
studio
Usage: android studio [-h] [COMMAND]
Connects Android CLI to a running Android Studio instance to analyze
files, find declarations and usages, render Compose previews, and look
up library versions
Options:
-h, --help Shows the help message for the specified command
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Commands:
analyze-file Analyzes a file in Android Studio
check Checks the status of running Android Studio
instances
find-declaration Finds the declaration of a symbol
find-usages Finds usages of a symbol
open-file Opens a file in Android Studio
render-compose-preview Renders a Compose preview in Android Studio
version-lookup Looks up the latest available versions of
Maven artifacts, Android versions, and SDK
tools
update
Usage: android update [-h] [--url=PARAM]
Updates Android CLI to the latest version
Options:
-h, --help Shows the help message for the specified command
--url=PARAM The URL to download the update from
android options:
--sdk=PARAM Path to the Android SDK
-v, --verbose Enable verbose output for troubleshooting
-V, --version Print version information and exit
Files
- ATTRIBUTION.mdAdded by AutoGineer948 B
- LICENSELicence file added by AutoGineer11.1 KiB
- SKILL.md42.3 KiB
LICENSE
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Needs network access
Security
What our scanner noticed· Medium risk
- Instructions that use the network
- Downloads piped into a shell
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Created by
- Google LLC
- Publisher
- Android (Google) (Official)
- Distributed by
- Android (Google)
- Source
- android/skills · devtools/android-cli · commit bf68e2d
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE.txt)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Google LLC or Android (Google).
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download android-cli.zip