Skip to main content
Glama

adb_file_write

Write or append text content to a file on an Android device via ADB. Supports root paths and overwrite or append modes, ideal for configs and scripts up to 128KB.

Instructions

Create or overwrite a text file on the device. Content is delivered via shell heredoc — suitable for config files, scripts, test fixtures, and small data files. For large or binary files, use adb_push instead. Shell buffer limits content to approximately 128KB.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesDestination file path on device
contentYesFile content to write
appendNoAppend to existing file instead of overwriting
rootNoUse root shell for protected paths
deviceNoDevice serial
Behavior3/5

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

Without annotations, the description discloses that content uses shell heredoc with a ~128KB limit, but lacks details on error handling, permissions needed for root, or side effects beyond overwrite/append. The behavioral profile is partially transparent.

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?

The description is two sentences with no filler. It front-loads the purpose, then adds limitations and alternatives. Every sentence contributes 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?

Given 5 parameters and no annotations or output schema, the description covers primary behavior, limitations, and an alternative. It lacks explicit details on root usage and error output, but is otherwise sufficient for an AI agent to use the tool correctly.

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% with descriptions for all 5 parameters. The description adds value by noting the buffer limit for the content parameter, but does not elaborate on other parameters beyond the schema. Baseline 3 is appropriate.

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?

The description clearly states the tool creates or overwrites a text file on the device, specifying the method (shell heredoc) and appropriate use cases (config files, scripts, test fixtures). It effectively distinguishes itself from sibling adb_push for large or binary files.

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?

The description explicitly tells when not to use the tool (large or binary files) and suggests adb_push as an alternative, plus mentions the 128KB buffer limit. It does not compare to other local file operations (e.g., adb_file_copy), but the primary alternative is clearly stated.

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/fullread/DeepADB'

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