Skip to main content
Glama

delete_branch

Delete a branch from a GitLab project repository while blocking accidental deletion of the default branch.

Instructions

Delete a branch from a project repository (blocks accidental deletion of default branch)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
branchYesName of the branch to delete
project_idYesProject numeric ID (e.g. 31) or namespace path (e.g. 'group/project-name'). URL-encoding is handled automatically.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

A3.7/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It usefully discloses one behavioral trait beyond the schema, namely that deletion of the default branch is blocked, but omits permissions required, irreversibility of the delete, and whether the action is recoverable.

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 front-loaded sentence with the verb and resource first, followed by a compact parenthetical caveat. No filler or redundant restatement of the name.

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?

For a two-parameter destructive tool with no annotations and no output schema, the description should ideally state permission requirements and whether the delete is permanent. The default-branch guard is a good start but leaves the safety context incomplete.

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 100%, so both 'branch' and 'project_id' are already well documented in the schema, including the ID-or-namespace-path formats. The description adds no parameter-level meaning beyond that, making the baseline 3 appropriate.

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?

The description pairs a specific verb ('Delete') with a precise resource ('a branch from a project repository'), so an agent can immediately tell this apart from sibling mutators like delete_project or delete_project_variable without opening the 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?

Usage is only implied by the operation itself; there is no explicit statement of when to use this versus get_branch/list_branches or any precondition like 'branch must be merged'. The parenthetical is a safety constraint, not routing guidance.

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