GitLab CI/CD · Capability
GitLab API — branches
GitLab API — branches. 8 operations. Lead operation: branches. Self-contained Naftiko capability covering one Gitlab Ci business surface.
What You Can Do
GET
Getapiv4projectsidrepositorybranches
— Get a project repository branches
/v1/api/v4/projects/{id}/repository/branches
POST
Postapiv4projectsidrepositorybranches
— Create branch
/v1/api/v4/projects/{id}/repository/branches
HEAD
Headapiv4projectsidrepositorybranchesbranch
— Check if a branch exists
/v1/api/v4/projects/{id}/repository/branches/{branch}
GET
Getapiv4projectsidrepositorybranchesbranch
— Get a single repository branch
/v1/api/v4/projects/{id}/repository/branches/{branch}
DELETE
Deleteapiv4projectsidrepositorybranchesbranch
— Delete a branch
/v1/api/v4/projects/{id}/repository/branches/{branch}
PUT
Putapiv4projectsidrepositorybranchesbranchprotect
— Protect a single branch
/v1/api/v4/projects/{id}/repository/branches/{branch}/protect
PUT
Putapiv4projectsidrepositorybranchesbranchunprotect
— Unprotect a single branch
/v1/api/v4/projects/{id}/repository/branches/{branch}/unprotect
DELETE
Deleteapiv4projectsidrepositorymergedbranches
— Delete all merged branches
/v1/api/v4/projects/{id}/repository/merged-branches
MCP Tools
get-project-repository-branches
Get a project repository branches
read-only
idempotent
create-branch
Create branch
check-if-branch-exists
Check if a branch exists
get-single-repository-branch
Get a single repository branch
read-only
idempotent
delete-branch
Delete a branch
idempotent
protect-single-branch
Protect a single branch
idempotent
unprotect-single-branch
Unprotect a single branch
idempotent
delete-all-merged-branches
Delete all merged branches
idempotent