Skip to main content
Glama

adb-app

Install, uninstall, launch, stop, clear data, or list Android applications on connected devices through ADB commands.

Instructions

Manage applications.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
operationYes
apkPathNoAPK path
packageNameNo
limitNoDefault: 20, max: 100
filterNoFilter by name (case-insensitive)
offsetNoPagination offset

Implementation Reference

  • Main handler function for the 'adb-app' tool. It delegates to specific operation functions (install, uninstall, etc.) based on the input.
    export async function handleAdbAppTool(
      input: AdbAppInput,
      context: ServerContext
    ): Promise<Record<string, unknown>> {
      const device = await context.deviceState.ensureDevice(context.adb);
      const handler = operations[input.operation];
      if (!handler) {
        throw new ReplicantError(
          ErrorCode.INVALID_OPERATION,
          `Unknown operation: ${input.operation}`,
          "Valid operations: install, uninstall, launch, stop, clear-data, list",
        );
      }
      return handler(input, device.id, context);
    }
  • Input schema definition for the 'adb-app' tool using Zod.
    export const adbAppInputSchema = z.object({
      operation: z.enum(["install", "uninstall", "launch", "stop", "clear-data", "list"]),
      apkPath: z.string().optional(),
      packageName: z.string().optional(),
      limit: z.number().min(1).max(100).optional(),
      filter: z.string().optional(),
      offset: z.number().min(0).optional(),
    });
  • Tool definition object for 'adb-app', used for registration.
    export const adbAppToolDefinition = {
      name: "adb-app",
      description: "Manage applications.",
      inputSchema: {
        type: "object",
        properties: {
          operation: {
            type: "string",
            enum: ["install", "uninstall", "launch", "stop", "clear-data", "list"],
          },
          apkPath: { type: "string", description: "APK path" },
          packageName: { type: "string" },
          limit: {
            type: "number",
            description: "Default: 20, max: 100",
          },
          filter: {
            type: "string",
            description: "Filter by name (case-insensitive)",
          },
          offset: {
            type: "number",
            description: "Pagination offset",
          },
        },
        required: ["operation"],
      },
      annotations: {
        readOnlyHint: false,
        destructiveHint: true,
        idempotentHint: false,
        openWorldHint: false,
      },
    };
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure but reveals nothing about side effects. It fails to warn that 'uninstall' and 'clear-data' operations permanently destroy data, or explain synchronous/asynchronous behavior and authentication requirements.

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

Conciseness2/5

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

While brief at only two words, the description is inadequately sized for a complex 6-parameter tool with six distinct operation modes. It is front-loaded with a generic verb but lacks subsequent sentences explaining constraints or operational modes.

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

Completeness1/5

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

Given the tool's complexity (multiple destructive operations, pagination support for listing, and conditional parameter requirements), the description is completely inadequate. With no output schema and no annotations, the description should explain return values and safety warnings, but provides neither.

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?

The description adds no context beyond the schema's 67% coverage. It does not explain the critical relationship between the 'operation' parameter and conditional requirements (e.g., 'install' requires 'apkPath' while 'uninstall' requires 'packageName'), leaving the agent to infer parameter dependencies from the schema alone.

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

Purpose2/5

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

The description 'Manage applications' is essentially a tautology that restates the tool name 'adb-app'. It fails to specify the scope of management (install, uninstall, launch, etc.) or distinguish from sibling tools like adb-shell which could also manipulate apps via command line.

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

Usage Guidelines1/5

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

No guidance is provided on when to use this tool versus alternatives like adb-shell, nor are prerequisites mentioned (e.g., requiring a connected device). The description lacks any indication of which operations are destructive or require specific parameters.

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/thecombatwombat/replicant-mcp'

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