Skip to main content
Glama

get_supervisor_kubeconfig

Idempotent

Retrieve a kubeconfig for the Supervisor Kubernetes API in a vSphere Namespace to authenticate with vCenter. Use only when explicitly requested; write to output_path to keep the token out of context.

Instructions

[WRITE] Credential access: get a kubeconfig for the Supervisor K8s API.

Call only when the user explicitly asks for this kubeconfig; never as a side step. Returns {namespace, kubeconfig} as a YAML string, or {namespace, written_to} when output_path is given. The kubeconfig embeds a Supervisor bearer token (JWT from /wcp/login) that acts as the configured vCenter account until the JWT expires (typically hours; not tied to this process) — always pass output_path so the token never enters agent context, and report only the path. The file is created owner-only (0600). Use get_tkc_kubeconfig instead to reach workloads inside a TKC cluster.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
targetNovCenter in config.yaml; omit for the default.
namespaceYesvSphere Namespace to set as the kubeconfig context.
output_pathNoFile to write, e.g. '~/.kube/supervisor.yaml'. Omit to return the kubeconfig inline. Creates parent directories and truncates the file.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.9.1
    • addedInput schema / properties / output_path
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "File to write, e.g. '~/.kube/supervisor.yaml'. Omit to return the kubeconfig inline. Creates parent directories and truncates the file.",
      +  "title": "Output Path"
      +}
  2. Changed3 schema fields changedv1.8.14
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / namespace / description
      Added value: +"vSphere Namespace to set as the kubeconfig context."
    • addedInput schema / properties / target / description
      Added value: +"vCenter in config.yaml; omit for the default."
  3. Addedv1.5.26
  4. Removedv1.5.23
  5. First observedv1.3.2

TDQS

A4.9/5.0
Behavior5/5

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

Goes well beyond the annotations (which only give the generic readOnly/idempotent/destructive/openWorld hints) by disclosing the exact return shapes, that the kubeconfig embeds a live Supervisor bearer token acting as the configured vCenter account, that the token lifetime is hours and not tied to the process, that the written file is mode 0600, and that output_path truncates and creates parent directories. This is exactly the kind of security-relevant behavioral context annotations cannot convey.

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?

Front-loads the [WRITE]/credential-access framing and the when-to-use gate, then return shapes, then the security rationale, then the sibling disambiguation. Every sentence carries distinct, load-bearing information with no filler.

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?

There is no output schema, and the description fully compensates by specifying both possible return payloads ({namespace, kubeconfig} vs. {namespace, written_to}), the token semantics, and file-permission behavior. Nothing an agent needs to invoke this credential-returning tool safely is missing.

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 coverage is 100%, so the baseline is 3, but the description adds real guidance the schema lacks: pass output_path preferentially so the token never enters agent context and only the path is reported. Target and namespace meaning is left to the schema, keeping this just under a 5.

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 ('get a kubeconfig for the Supervisor K8s API') and immediately distinguishes itself from the near-identical sibling get_tkc_kubeconfig by scope (Supervisor API vs. workloads inside a TKC cluster). An agent can select correctly 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 Guidelines5/5

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

Explicit when-to-use constraint ('Call only when the user explicitly asks for this kubeconfig; never as a side step') and an explicit named alternative ('Use get_tkc_kubeconfig instead to reach workloads inside a TKC cluster'). Both the positive and negative routing conditions are stated.

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