Skip to main content
Glama

Uninstall an app

android_uninstall
DestructiveIdempotent

Remove an Android app from a device to resolve installation conflicts or test a clean first-run state. It deletes app data and cache unless keep_data is set.

Instructions

Remove an app from the device. This deletes the app's data and cannot be undone.

Args:

  • package_name (string, optional): application id to remove

  • project_path (string, optional): Gradle root; the package is resolved from it when package_name is omitted

  • module (string): module to read the package from (default: 'app')

  • serial (string, optional): target device

  • keep_data (boolean): keep app data and cache directories (adb uninstall -k) (default: false)

Returns: { "uninstalled": boolean, "packageName": string, "serial": string }

Examples:

  • Use when: an install fails with INSTALL_FAILED_UPDATE_INCOMPATIBLE and the old copy must go

  • Use when: testing a first-run experience from a clean state

  • Don't use when: you only want to clear state; force-stopping or clearing data is less destructive

Error Handling:

  • Reports when the package was not installed to begin with

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
moduleNoGradle module that produces the APK. Almost always 'app'.app
serialNoDevice serial from android_list_devices. Optional when exactly one device is connected; required when several are.
keep_dataNoRetain the app's data and cache directories.
package_nameNoApplication id to uninstall.
project_pathNoGradle root to resolve the package from.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The annotations already indicate destructiveHint=true and idempotentHint=true, but the description adds critical context: 'deletes the app's data and cannot be undone', the effect of keep_data ('adb uninstall -k'), and error behavior ('Reports when the package was not installed to begin with'). No contradictions with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Structured with clear sections (Description, Args, Returns, Examples, Error Handling). Front-loaded with the core purpose and destructive warning. Every sentence contributes useful information without redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (5 parameters, no output schema), the description covers the return format, example use cases, error handling, and parameter resolution logic. It is self-contained and fully prepares the agent to invoke the tool correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

While schema coverage is 100%, the description adds relational semantics: 'project_path... package is resolved from it when package_name is omitted' and clarifies keep_data as 'keep app data and cache directories (adb uninstall -k)'. This goes beyond the schema's per-field definitions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with 'Remove an app from the device', which is a specific verb+resource statement. It further clarifies destructive consequences and distinguishes from sibling tools like android_clear_data by explicitly stating when uninstall is appropriate (e.g., INSTALL_FAILED_UPDATE_INCOMPATIBLE) versus when a less destructive alternative should be used.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit use cases: 'Use when: an install fails with INSTALL_FAILED_UPDATE_INCOMPATIBLE...' and 'Use when: testing a first-run experience'. It also gives a clear exclusion: 'Don't use when: you only want to clear state; force-stopping or clearing data is less destructive', naming the alternative.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jjs03111/android-build-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server