Skip to main content
Glama

connect_gitops_repository

Destructive

Connect a GitOps repository to a cluster that has none: bind an existing GitHub credential plus a repository and branch - the same binding the portal's GitOps step creates. Pick the credential from list_gitops_credentials (pass credential_id, or credential_name when unambiguous) and the repository from list_gitops_repositories: it must be in the credential's synced repository list. On confirm the binding is written to the cluster's resource graph, a repository webhook is provisioned best-effort, the current cluster state is pushed to the repository as an initial commit, and a sync is nudged so the repository and the cluster record converge. Refused when the cluster is already connected to a DIFFERENT GitOps source: repointing prunes everything the new source does not define, so it stays on the cluster settings flow with its explicit acknowledgements. Re-connecting the identical repository and branch is safe and just refreshes the binding.

Input Schema

NameRequiredDescriptionDefault
branchYesThe branch the cluster's GitOps state lives on, e.g. main.
cluster_idNoCluster UUID. Optional when the chat is already scoped to a cluster.
repositoryYesThe repository's full name in owner/name form, e.g. ankraio/values.
credential_idNoUUID of the GitHub credential from list_gitops_credentials. Preferred over credential_name.
credential_nameNoName of the GitHub credential; refused when more than one credential shares the name.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only say destructive=true and idempotent=false; the description goes well beyond them by enumerating the side effects on confirm (resource-graph write, best-effort webhook provisioning, initial commit of cluster state, sync nudge) and the refusal/prune behavior on repointing. It even clarifies the safe re-connect case, which is exactly the nuance an agent needs given the destructive hint.

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?

Long but dense: purpose, input sourcing, side effects, and refusal behavior are front-loaded and each sentence adds distinct operational information. Slightly heavier than necessary, but nothing is padding.

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?

With no output schema, the description carries the return/effect burden and does so: it describes what is written, what is provisioned, what is pushed, and when the call is refused. An agent has everything needed to call it correctly and predict the outcome.

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 semantics: credential_id is preferred over credential_name, credential_name is refused when ambiguous, and repository must appear in the credential's synced repository list. This is meaningfully more than the schema fields carry.

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?

Opens with a specific verb+resource+scope: 'Connect a GitOps repository to a cluster that has none', and pins the scope further with 'bind an existing GitHub credential plus a repository and branch'. It also names the related lookup siblings (list_gitops_credentials, list_gitops_repositories), so an agent can place it precisely in the GitOps flow.

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?

Explicitly states where inputs come from ('Pick the credential from list_gitops_credentials ... and the repository from list_gitops_repositories'), the precondition that the repo must be in the credential's synced list, and a clear when-not: refused when the cluster is already connected to a different GitOps source, which must go through the cluster settings flow instead.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources