Skip to main content
Glama

current_app

Read-only

Retrieves the foreground Android package and activity, optionally by device serial, so automation can target the active app.

Instructions

Package and activity in the foreground.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
serialNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.2

TDQS

C2.4/5.0
Behavior2/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false, so the safety profile is covered. The description adds essentially nothing beyond restating the likely return value (foreground package and activity), which the output schema already covers. No mention of refresh/latency, multi-device behavior, or what happens when no app is in the foreground.

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?

A single short sentence with zero filler, front-loaded and easy to scan. It is efficient, though its brevity is closer to under-specification than genuine economy.

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

Completeness2/5

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

Although an output schema exists (so return structure need not be described), the definition leaves the device-selection parameter unexplained and gives no indication of when in a workflow this check should be used. For a device-automation tool with 12 siblings, that is a meaningful gap.

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

Parameters2/5

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

There is one parameter, 'serial', with 0% schema description coverage and a default of empty string. The description never explains that this selects the target device or what the empty default implies (e.g., default device). With one undocumented parameter, the description fails to compensate for the coverage gap.

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

Purpose3/5

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

The phrase 'Package and activity in the foreground' identifies the resource being queried (the foreground app's package/activity), which is distinct from siblings like list_apps or launch_app. However, it is a noun fragment with no verb, so the agent must infer that this is a read/query operation rather than a state change. Minimum viable but not explicit.

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

Usage Guidelines2/5

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

No guidance is given about when to call this versus alternatives such as list_apps or screen_elements, nor any prerequisites or ordering constraints within a device-automation flow. The agent must guess whether this is a precondition check for tapping/typing or a standalone query.

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