Skip to main content
Glama

apk_diff

Compare two APK builds to reveal changes in SDK levels, security flags, permissions, exported components, native-library hashes, secrets, and archive contents for mobile app security review.

Instructions

Diffs two builds of the same app (APK vs APK): identity/SDK levels, security flags, permission and exported-component deltas, native-library changes (sha256), optional secret deltas and an archive inventory.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "old_path": "<old_path>",
      "new_path": "<new_path>"
    },
    "name": "apk_diff"
  }
}

Input Schema

NameRequiredDescriptionDefault
new_pathYesAbsolute path to the newer APK
old_pathYesAbsolute path to the older APK
skip_secretsNoSkip the (slower) secret-scan diff; default false

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.3.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It does valuable work by disclosing the comparison surface and flagging that secret deltas are optional/slower, but it says nothing about the cost of the base diff, whether both files must exist locally and be readable, what happens if the two APKs are unrelated apps, or the shape of the result (no output schema exists).

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 front-loaded sentence with the verb and subject first, followed by the enumerated delta categories. Zero filler, though the list is dense enough that it reads as a spec dump rather than prose; it still earns its length by telling the agent what the diff returns.

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

Completeness3/5

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

For a moderately complex two-input comparison tool with no annotations and no output schema, the description covers what is compared but not the result format, ordering, or failure modes. Enough to select the tool, not quite enough to predict its output or preconditions.

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

Parameters3/5

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

Schema coverage is 100% and all three parameters are documented in-schema, so the baseline is 3. The description adds only the notion of "optional secret deltas," which corroborates but does not meaningfully extend the existing skip_secrets description; no extra semantics for old_path/new_path ordering beyond what the schema states.

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?

"Diffs two builds of the same app (APK vs APK)" gives a specific verb (diff) and resource (two APK builds), then enumerates the exact comparison surface: identity/SDK levels, security flags, permission and exported-component deltas, native-library sha256 changes, secret deltas, archive inventory. The comparative framing immediately separates it from the single-target sibling analyzers (apk_manifest_analyzer, apk_permissions_checker, etc.) without opening any schema.

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

Usage Guidelines3/5

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

Usage is implied rather than prescribed: the phrase "two builds of the same app" tells the agent the comparison must be between related APKs, and "skip the secret scan" is exposed in the schema. There is no explicit when-to-use versus when-not guidance, nor any pointer to running the individual analyzers instead when only one build needs inspection.

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