GitLab Extended icon

GitLab Extended

Extended GitLab node

Overview

The node "GitLab Extended" provides extended integration with GitLab, allowing users to manage various GitLab resources such as branches, pipelines, tags, releases, groups, projects, issues, merge requests, files, and raw API calls. Specifically for the Branch - Unprotect operation, this node allows users to remove protection from a specified branch in a GitLab project.

This is useful in scenarios where a protected branch needs to be made editable by more users or automated processes, for example:

  • Temporarily unprotecting a branch to allow emergency fixes.
  • Automating branch management workflows that require toggling protection status.
  • Integrating GitLab branch management into broader CI/CD or DevOps pipelines.

Properties

Name Meaning
Authentication Choose between using saved credentials ("Credential") or providing custom connection details ("Custom") such as GitLab server URL and access token.
GitLab Server Base URL of your GitLab instance (e.g., https://gitlab.com). Only shown if "Custom" authentication is selected.
Access Token Personal access token with API permissions for authenticating API requests. Only shown if "Custom" authentication is selected.
Project Owner Namespace or owner of the project. Ignored if "Project ID" is set. Only shown if "Custom" authentication is selected.
Project Name Project slug or name. Ignored if "Project ID" is set. Only shown if "Custom" authentication is selected.
Project ID Numeric project ID. Takes precedence over owner and name if provided. Only shown if "Custom" authentication is selected.
Branch The name of the branch to unprotect, e.g., feature/login. This is a required field for the unprotect operation.

Output

The node outputs an array of JSON objects representing the response from the GitLab API after performing the requested operation. For the Unprotect Branch operation, the output JSON typically contains details about the branch after it has been unprotected, including its name and protection status.

No binary data output is involved in this operation.

Dependencies

  • Requires access to a GitLab instance, either the public GitLab.com or a self-hosted GitLab server.
  • Requires an API access token with sufficient permissions to modify branch protection settings on the target project.
  • If using saved credentials, those must be configured in n8n with appropriate API access.
  • No additional external dependencies beyond standard HTTP API calls to GitLab.

Troubleshooting

  • Invalid or missing credentials: Ensure the access token has the necessary API scopes to manage branch protections.
  • Project identification errors: When using custom authentication, provide either a valid numeric project ID or both project owner and project name. The project ID takes precedence.
  • Branch not found: Verify the branch name exists in the specified project.
  • Permission denied: The user associated with the access token must have sufficient rights to unprotect branches.
  • API rate limits: Be aware of GitLab API rate limits which may cause temporary failures.

Common error messages:

  • "404 Not Found": The specified branch or project does not exist.
  • "403 Forbidden": Insufficient permissions to modify branch protection.
  • "401 Unauthorized": Invalid or expired access token.

Resolving these usually involves checking credentials, project identifiers, and user permissions.

Links and References

Discussion