Skip to main content
Glama

list_branches

Read-only

List or search branches in a CERN GitLab repository and get branch names plus commit metadata for use as a ref in content and code-search tools.

Instructions

List or search branches in a CERN GitLab repository. Returns branch names and commit metadata so a branch can be selected and passed as the 'ref' argument to repository content and code-search tools.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pageNoPage number to retrieve
searchNoOptional branch-name filter. GitLab supports partial matches and anchors such as '^main$' for an exact match.
projectYesProject identifier — either a numeric ID (e.g. '12345') or a URL-encoded path (e.g. 'atlas/athena')
per_pageNoNumber of branches to return

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed12 schema fields changedv0.3.0
    • addedInput schema / properties / page / default
      Added value: +1
    • changedInput schema / properties / page / description
      Previous value: -"Page number to retrieve (default: 1)"New value: +"Page number to retrieve"
    • addedInput schema / properties / page / title
      Added value: +"Page"
    • addedInput schema / properties / per_page / default
      Added value: +20
    • changedInput schema / properties / per_page / description
      Previous value: -"Number of branches to return (default: 20, max: 100)"New value: +"Number of branches to return"
    • addedInput schema / properties / per_page / title
      Added value: +"Per Page"
    • changedInput schema / properties / project / description
      Previous value: -"Project identifier — either a numeric ID (e.g. '12345') or a path (e.g. 'atlas/athena')"New value: +"Project identifier — either a numeric ID (e.g. '12345') or a URL-encoded path (e.g. 'atlas/athena')"
    • addedInput schema / properties / project / title
      Added value: +"Project"
    • addedInput schema / properties / search / default
      Added value: +""
    • addedInput schema / properties / search / title
      Added value: +"Search"
    • addedInput schema / title
      Added value: +"list_branches_fnArguments"
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "title": "list_branches_fnDictOutput",
      +  "type": "object"
      +}
  2. Addedv0.2.0

TDQS

A4.1/5.0
Behavior3/5

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

The readOnlyHint annotation already covers the safety profile. The description adds that results include branch names and commit metadata, plus the intended downstream use, which is useful context. It does not disclose pagination defaults or ordering behavior, but those are partly covered by the schema and output schema.

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?

The description is two sentences with no filler. The core action and scope are front-loaded, and the second sentence adds practical guidance about why the output matters. Every sentence earns its place.

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?

For a low-complexity listing tool with a fully documented schema, an output schema, and a readOnly annotation, the description is complete. It tells the agent what the tool does, what it returns, and how the result should be used in subsequent calls.

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 the schema already documents all parameters well. The description reinforces the purpose of the returned branch names but does not add substantial parameter-level meaning beyond what the schema provides.

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 states a specific verb ('List or search'), a clear resource ('branches in a CERN GitLab repository'), and reveals the downstream purpose (supplying a 'ref' argument). This makes it easy to distinguish from sibling tools like list_tags or list_releases.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

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

The description clearly identifies when the tool is useful: when a branch needs to be selected and passed as a 'ref' to repository content or code-search tools. It does not explicitly state exclusions or when not to use it, but the context is sufficiently clear.

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