Skip to main content
Glama

Get app details

get_app_details
Read-only

Read an installed app's version name/code and launchable activity, or inspect a local APK's package ID, version, and launcher activity without a device.

Instructions

Report an installed app's version name/code and its launchable activity (dumpsys package + resolve-activity) — to confirm what build is installed and find the activity to launch. Pass apk_path instead of package to read a local .apk (package id, version, launcher activity) with no device attached — handy right after gradle_build.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_app_details"
  }
}

Input Schema

NameRequiredDescriptionDefault
serialNoTarget device serial (adb -s). Optional when exactly one device is attached.
packageNoInstalled application package name (e.g. com.example.app). Required unless apk_path is given.
apk_pathNoLocal path to an .apk to read instead of querying a device: returns its package id, version and launcher activity via aapt2. Needs no device; use it right after a build to get the applicationId.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.24.3
    • addedInput schema / properties / apk_path
      Added value: +{
      +  "description": "Local path to an .apk to read instead of querying a device: returns its package id, version and launcher activity via aapt2. Needs no device; use it right after a build to get the applicationId.",
      +  "type": "string"
      +}
    • changedInput schema / properties / package / description
      Previous value: -"Application package name (e.g. com.example.app)."New value: +"Installed application package name (e.g. com.example.app). Required unless apk_path is given."
    • removedInput schema / required
      Removed value: -[
      -  "package"
      -]
  2. First observedv1.0.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnlyHint=true, openWorldHint=false), and the description is consistent with a pure read. It adds real value beyond annotations by disclosing the underlying commands, that apk_path mode requires no attached device (aapt2), and what is returned in each mode. It stops short of stating behavior when the package is not installed or the apk path is invalid.

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

Conciseness4/5

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

Two sentences, front-loaded with the primary outcome (version + launchable activity) before the alternate mode. Parenthetical implementation details are dense but each reinforces a distinct fact; no filler text.

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

Completeness4/5

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

For a 3-parameter, read-only tool with annotations and no output schema, the description supplies what an agent needs: what is returned in both modes, when the device is unnecessary, and the fallback if no device is attached via the optional serial.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds mode-selection semantics: apk_path substitutes for package and switches to an offline aapt2 read that yields package id, version and launcher activity. The mutual-exclusivity relationship between package and apk_path is reinforced beyond the schema wording.

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?

States a specific verb and resource: reports an installed app's version name/code plus its launchable activity. It names the underlying mechanisms (dumpsys package + resolve-activity) and clearly separates the two modes (device query vs. local .apk read), which distinguishes it from siblings like list_packages or app_state.

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

Usage Guidelines4/5

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

Gives explicit when-to-use framing: 'to confirm what build is installed and find the activity to launch', plus a stated condition for the alternate mode ('pass apk_path instead of package... no device attached — handy right after gradle_build'). It does not name sibling tools it replaces or should be preferred over, so routing against list_packages/app_state is left to inference.

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