Skip to main content
Glama

Port forward pod

k8s_port_forward_pod

Establish a WebSocket port forward to a Kubernetes pod, mapping local and remote ports to access pod services from your local machine.

Instructions

Port forward to a pod using WebSocket streaming.

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": {
      "pod_name": "<pod_name>"
    },
    "name": "k8s_port_forward_pod"
  }
}

Input Schema

NameRequiredDescriptionDefault
contextNoNamed context of the multi-context pool to run against (see cm_multi_context list_contexts); the default context if omitted.
pod_nameYes
namespaceNo
local_portNo
remote_portNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.4.2

TDQS

C2.4/5.0
Behavior2/5

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

The annotations already declare readOnlyHint=false, destructiveHint=false, and openWorldHint=true, so the safety profile is covered. The description adds only the transport detail ('WebSocket streaming') and says nothing about session lifetime, whether the call blocks, how to tear down the tunnel, or what local port binding implies. For a long-lived streaming connection, that is a real gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

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

The description is a single, front-loaded sentence with no filler. It is concise but also under-specified for a five-parameter streaming tool, so its brevity is a limitation rather than a strength.

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

Completeness2/5

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

With five parameters, one required, no output schema, and only 20% schema coverage, the definition leaves most of the operational picture unexplained. An agent cannot tell how ports are chosen or what the response looks like. The definition is not adequate for the tool's complexity.

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

Parameters1/5

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

Schema description coverage is 20%: only the context parameter is documented in the schema. The description does not explain pod_name, namespace, local_port, or remote_port, or how the default local 8080 maps to remote 80. It therefore does not compensate for the coverage 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 description names a specific verb and resource: 'Port forward to a pod'. Combined with the WebSocket detail, the action is unambiguous. It does not distinguish this tool from adjacent siblings such as k8s_exec_pod or k8s_attach_pod, so sibling differentiation is missing, but the core purpose is clear.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no guidance on when to use this tool, no prerequisites, and no mention of alternatives. It doesn't clarify when tunneling is preferable to exec/attach, and it doesn't say whether the call blocks or how the tunnel is closed.

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