Skip to main content
Glama

branches

Destructive

Manage branches, compare refs, and configure branch protection rules. Use 'compare' to see commits reachable from head but not base. Protection actions manage merge requirements, status checks, and push restrictions.

Input Schema

NameRequiredDescriptionDefault
baseNoBase ref. For compare
headNoHead ref. For compare
nameNoProtection rule name (glob pattern). For get/update/delete_protection
pageNoPage number. For list
repoYesRepository name
limitNoPage size. For list
ownerYesRepository owner
actionYesOperation to perform
branchNoBranch name. For create/delete
rule_nameNoGlob pattern for the new rule. For create_protection
old_branchNoSource branch to create from. For create
enable_pushNoAllow whitelisted users/teams to push. For create/update_protection
required_approvalsNoMinimum approving reviews required. For create/update_protection
enable_status_checkNoRequire status checks before merging. For create/update_protection
push_whitelist_teamsNoComma-separated teams allowed to push. For create/update_protection
enable_push_whitelistNoRestrict direct pushes to whitelist. For create/update_protection
merge_whitelist_teamsNoComma-separated teams allowed to merge. For create/update_protection
status_check_contextsNoComma-separated required status check contexts. For create/update_protection
enable_merge_whitelistNoRestrict merging to whitelist. For create/update_protection
require_signed_commitsNoRequire signed commits. For create/update_protection
dismiss_stale_approvalsNoDismiss approvals on new pushes. For create/update_protection
protected_file_patternsNoSemicolon-separated glob patterns of protected files. For create/update_protection
block_on_outdated_branchNoBlock merge when branch is outdated. For create/update_protection
push_whitelist_usernamesNoComma-separated usernames allowed to push. For create/update_protection
approvals_whitelist_teamsNoComma-separated teams whose approvals count. For create/update_protection
block_on_rejected_reviewsNoBlock merge on rejected reviews. For create/update_protection
merge_whitelist_usernamesNoComma-separated usernames allowed to merge. For create/update_protection
unprotected_file_patternsNoSemicolon-separated glob patterns exempt from protection. For create/update_protection
enable_approvals_whitelistNoRestrict approvals to whitelist. For create/update_protection
push_whitelist_deploy_keysNoAllow deploy keys to push. For create/update_protection
approvals_whitelist_usernameNoComma-separated usernames whose approvals count. For create/update_protection
block_on_official_review_requestsNoBlock merge on pending review requests. For create/update_protection

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

B3.4/5.0
Behavior3/5

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

Annotations declare destructiveHint=true, readOnlyHint=false and idempotentHint=false, and the description adds a genuinely useful behavioral nuance about compare direction. But for a mixed read/write tool it never splits safe reads (list/get/compare) from destructive ones (delete/delete_protection), and it says nothing about irreversibility or permission requirements.

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?

Three sentences, front-loaded with the capability summary followed by compare semantics and protection scope. No filler, though the action-level mapping that would help most is omitted rather than the text being bloated.

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 9-action, 32-parameter, destructive tool with no output schema, the description gives a reasonable capability map but no per-action guidance, no indication of which actions mutate state, and no sense of return shape. It is the minimum viable overview rather than a complete one.

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% and every parameter already carries an 'For <action>' tag, so the schema does the heavy lifting. The description adds the head/base direction semantics that the schema wording ('Base ref. For compare') does not convey, but that covers only 2 of 32 parameters.

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?

States a specific verb set and resource ('Manage branches, compare refs, configure branch protection rules'), which lets an agent distinguish branch operations from sibling tools like commits or repos. However, the nine concrete actions (list/create/delete/protection CRUD) are only implied by the schema enum, not named in the description.

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 points at one action explicitly ('Use \'compare\' to see commits reachable from head but not base') and groups the protection actions, so usage is partly implied. It never states when-not to use this tool or routes between overlapping actions (e.g. list vs list_protections, create_protection vs update_protection).

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.