Skip to main content
Glama

adb_clipboard

Read or write the Android device clipboard via ADB so AI agents can retrieve copied text or set clipboard content during device automation.

Instructions

Read or write the device clipboard. Write mode sets the clipboard content; read mode retrieves it. Clipboard access requires Android 10+ and may need the app to be in foreground on Android 12+.

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": {
      "action": "<action>"
    },
    "name": "adb_clipboard"
  }
}

Input Schema

NameRequiredDescriptionDefault
textNoText to write to clipboard (required when action='write')
actionYes'read' to get clipboard, 'write' to set it
deviceNoDevice serial

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.1.6
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Changed1 schema field changedv1.1.3
    • removedInput schema / additionalProperties
      Removed value: -false
  3. First observedv1.1.1

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 behavioral burden, and it does disclose the Android 10+ requirement plus a possible foreground requirement on Android 12+. It omits permission prompts, overwrite behavior, failure modes, and the return/format semantics for read mode.

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?

It is three short sentences with no filler, front-loading the core purpose and then adding mode and compatibility details. Every sentence contributes useful information.

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 simple three-parameter tool with complete schema descriptions and no output schema, the description covers purpose and platform constraints adequately. It leaves minor gaps around what read mode returns and how write failures surface.

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 description coverage is 100%, with action, text, and device all documented, including that text is required for write. The description adds only a restatement of read/write behavior and no additional parameter constraints or formats, so the baseline 3 applies.

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

Purpose4/5

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

The opening sentence gives a specific verb pair and resource: read/write the device clipboard, and the second sentence disambiguates the two modes. No sibling tool is explicitly named or contrasted, such as adb_input_text, so it stops short of a 5.

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?

The action enum and mode explanation make the basic use case clear, and the Android 10+/foreground constraint helps the agent anticipate conditions. However, it gives no explicit when-to-use versus alternatives or when-not guidance, so usage is mostly implied.

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

Deploy Server

Other Tools