Skip to main content
Glama

List port forwards

list_forwards
Read-onlyIdempotent

List a device's active forward socket connections as JSON objects with serial, local, and remote fields. Returns an empty array when no forwards exist.

Instructions

List the forward socket connections of one device (adb forward --list) as a JSON array of {serial, local, remote} objects (empty array when there are none).

Input Schema

NameRequiredDescriptionDefault
deviceNoDevice serial from list_devices; optional when exactly one device is connected.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.6.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint=false, so the safety profile is covered. The description adds genuinely useful behavior beyond that: the exact return shape ({serial, local, remote} JSON array) and the empty-array edge case, which matters because 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.

Conciseness5/5

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

One sentence, front-loaded with the action and resource, with the return format appended as a compact clause. Nothing is redundant or padded.

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

Completeness5/5

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

For a single-optional-param read tool, the description covers purpose, the CLI equivalent, and the return value shape and empty case. With annotations handling safety and no output schema present, nothing an agent needs to invoke it correctly is missing.

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% for the single `device` parameter, including the 'optional when exactly one device is connected' nuance. The description adds nothing about the parameter, so the baseline 3 for schema-does-the-work 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?

States a specific verb and resource ('List the forward socket connections of one device') and pins it to the underlying operation (`adb forward --list`), which cleanly distinguishes it from siblings like list_reverses, forward_port, and remove_forward.

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 by the name and the read-only listing nature of the tool, but there is no explicit when-to-use guidance and no mention of the obvious alternative (list_reverses for reverse forwards). The agent can infer intent, but nothing routes it deliberately.

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