Skip to main content
Glama

Cp pod

k8s_cp_pod

Copy files to or from a Kubernetes pod by specifying source and destination paths; direction is inferred automatically for local-to-pod or pod-to-local transfers.

Instructions

Copy files to/from a pod, delegating to :meth:copy_to_pod / :meth:copy_from_pod.

Direction is inferred from the paths (an absolute pod source or a non-absolute local destination means pod-to-local). The real kubectl cp transfer — and its path-traversal safety — lives in the two delegate methods; this wrapper carries no tar logic of its own.

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_cp_pod"
  }
}

Input Schema

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

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.4.2

TDQS

A3.6/5.0
Behavior4/5

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

The annotations already declare the operation as not read-only, not destructive, and open-world. The description adds useful behavioral context beyond that: it delegates the real kubectl cp transfer to copy_to_pod/copy_from_pod, notes that path-traversal safety lives in those delegates, and clarifies that the wrapper carries no tar logic. It still omits overwrite semantics and failure behavior, but it provides meaningful transparency for a mutation wrapper.

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?

The description is front-loaded with the core action and remains reasonably short. Some implementation detail, such as references to :meth: delegates and the absence of tar logic, is less directly useful for tool selection but still clarifies behavior rather than padding.

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?

Given five parameters, low schema description coverage, and no output schema, the description covers the high-level delegation model and direction inference. However, it leaves a critical operational gap: how exactly to format pod paths versus local paths, and what happens when a destination file exists. It is adequate but not complete for reliable invocation.

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 low at 20%, so the description should compensate. It does explain the directional meaning of source and destination paths, which is valuable, but it does not clarify exact path syntax or meaning for the remaining parameters beyond what the schema already implies. The partial compensation merits a middle score.

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 opens with a specific verb and resource: "Copy files to/from a pod." It also explains that direction is inferred from the paths, which is relevant to how the tool works. However, it does not explicitly differentiate this unified copy operation from the directional sibling tools k8s_copy_from_pod and k8s_copy_to_pod.

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 direction is inferred from source/destination paths, but it gives no explicit guidance about when to choose this tool over k8s_copy_from_pod, k8s_copy_to_pod, or other pod file-transfer alternatives. There are no exclusions or prerequisites stated.

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