Actions66
- Branch Actions
- File Actions
- Group Actions
- Issue Actions
- Merge Request Actions
- Pipeline Actions
- Project Actions
- Raw API Actions
- Release Actions
- Tag Actions
Overview
This node interacts with GitLab's API to perform various operations on merge requests within a GitLab project. Specifically, the Get operation for the Merge Request resource retrieves detailed information about a single merge request identified by its internal ID (IID) within a project.
Typical use cases include:
- Fetching the current status and details of a specific merge request.
- Automating workflows that depend on merge request metadata, such as approvals, pipeline statuses, or comments.
- Integrating GitLab merge request data into other systems or dashboards.
For example, you might use this node to get the details of a merge request before triggering a deployment or sending notifications.
Properties
| Name | Meaning |
|---|---|
| Authentication | Choose between using saved credentials or providing custom connection details for GitLab access. Options: Credential, Custom |
| GitLab Server | Base URL of your GitLab instance (only shown if using Custom authentication). Default: https://gitlab.com |
| Access Token | Personal access token with API permissions (only for Custom authentication). |
| Project Owner | Namespace or owner of the project; ignored if Project ID is set (Custom authentication only). |
| Project Name | Project slug or name; ignored if Project ID is set (Custom authentication only). |
| Project ID | Numeric project ID; takes precedence over owner and name if provided (Custom authentication only). Default: 0 |
| Merge Request IID | The internal ID of the merge request to retrieve. Must be a positive number. Default: 1 |
Output
The node outputs JSON data representing the full details of the requested merge request. This includes fields such as:
- Merge request title, description, and state (open, closed, merged).
- Source and target branches.
- Author and assignee information.
- Timestamps for creation, updates, and merges.
- Labels, milestones, and related metadata.
- Pipeline and approval status if available.
No binary data output is produced by this operation.
Dependencies
- Requires access to a GitLab instance via an API token with appropriate permissions to read merge requests.
- Supports two authentication modes:
- Using saved credentials configured in n8n.
- Providing custom connection details including server URL and personal access token.
- No additional external dependencies beyond standard HTTP requests to the GitLab API.
Troubleshooting
- Invalid or missing Merge Request IID: Ensure the IID is a positive integer and corresponds to an existing merge request in the specified project.
- Authentication errors: Verify that the API token has sufficient permissions to access the project and merge requests.
- Project identification issues: If using custom authentication, ensure either the numeric Project ID is set correctly or both Project Owner and Project Name are provided.
- API rate limits or network errors: Check connectivity to the GitLab server and consider retrying after some time if rate limited.
Common error messages may include:
- "Unknown resource" if the resource parameter is incorrect.
- "Invalid project credentials" if authentication fails.
- HTTP 404 if the merge request or project does not exist.
Resolving these typically involves verifying input parameters and credentials.