Skip to main content
Glama

forward_port

Map a host TCP port to a device TCP port so traffic sent locally reaches the Android device. Use to expose device services to your host machine.

Instructions

adb forward tcp:local tcp:remote — forward a HOST port to a DEVICE port (host connects locally, traffic reaches the device).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
serialNo
local_portYes
remote_portYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It explains the direction of forwarding but says nothing about persistence (does the forward survive disconnect?), required device connectivity, port conflicts, permissions, or cleanup via remove_forward/clear_forwards. For a state-mutating setup tool, this is a significant gap.

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?

A single sentence that front-loads the adb equivalent and then clarifies the direction. No filler; every clause earns its place.

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

Completeness3/5

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

With no annotations and 0% schema description coverage, the description should do more. It covers the core semantics but omits prerequisites, lifecycle (persistence/removal), and error conditions, and never references the related remove_forward or clear_forwards tools. An output schema exists, so return values needn't be explained.

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 0%, so the description must compensate. It successfully maps local_port to the host port and remote_port to the device port via the `adb forward tcp:local tcp:remote` syntax, but the optional `serial` parameter is never mentioned, leaving one of three parameters undocumented.

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 ('forward a HOST port to a DEVICE port') and explicitly defines the direction of traffic, which is the key distinction from the sibling reverse_port. An agent can tell it apart from reverse_port without opening either schema.

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 description implies usage by explaining that host connects locally and traffic reaches the device, but it never states when to use this versus reverse_port, nor does it name any alternatives or prerequisites (e.g., device must be connected). Usage is inferable but not guided.

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