Skip to main content
Glama

adb_logcat

Read-only

Retrieve recent Android logcat lines non-blocking, optionally filter by tag/priority, and clear the buffer after reading to debug device issues.

Instructions

Dump recent Android logcat lines (non-blocking).

Args: lines: number of most recent lines to return. filter_spec: optional logcat filter, e.g. "ActivityManager:I :S" or ":E". clear: clear the log buffer after reading.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "adb_logcat"
  }
}

Input Schema

NameRequiredDescriptionDefault
clearNo
linesNo
deviceNo
filter_specNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior2/5

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

The description does add real behavioral context that annotations do not cover: the call is non-blocking, the buffer can be cleared, and clearing happens after reading. However, 'clear the log buffer after reading' is a state-destroying action, which conflicts with the supplied readOnlyHint=true; the destructive capability is disclosed in text but is not reconciled with the annotation.

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?

Short and front-loaded: the one-line summary states the action and its non-blocking nature before any argument details. The args list is terse and every line carries information, though the bare arg names could be formatted to read more cleanly.

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?

An output schema exists, so return format need not be described. With zero schema description coverage the description does a reasonable job covering parameter meaning and blocking behavior; only the 'device' target parameter and any permission/connection prerequisites are left unaddressed.

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

Parameters4/5

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

Schema description coverage is 0%, so the description must carry the load; it documents 3 of the 4 parameters (lines, filter_spec, clear) and adds a concrete syntax example for filter_spec ('ActivityManager:I *:S', '*:E') plus ordering semantics for clear. The fourth parameter, 'device', is never mentioned, which is the only material gap.

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 first sentence names a specific verb and resource: dumping recent Android logcat lines, plus the key behavioral fact that it is non-blocking. It does not differentiate from siblings such as adb_shell, which could also be used to read logs, 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?

'Dump recent ... logcat lines' implies the use case (retrieving device logs) but gives no explicit when-to-use, when-not-to-use, or alternative. An agent must infer on its own that adb_shell with a 'logcat' command is the sibling alternative, and whether prerequisite device setup (adb_connect) is needed.

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