GitLab API

GitlabTool

Actions905

Overview

This node operation retrieves the versions of a specific merge request in a GitLab project using the GitLab API v4. It is useful for tracking changes and reviewing the history of a merge request's versions. For example, developers can use this to audit changes made to a merge request over time or to compare different versions before merging.

Use Case Examples

  1. Retrieve all versions of merge request IID 42 in project ID 'my-group/my-project' to review changes made during the review process.
  2. Paginate through versions of a merge request to display them in a custom dashboard.

Properties

Name Meaning
Skip Authentication Whether to skip authentication for the API request.
Authentication The authentication method used for the API request, typically an API key credential.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method The HTTP method to use for the request, default is GET.
Query Parameters Optional query parameters for pagination, including page number and items per page.
Path Parameters Required path parameters identifying the project and merge request.

Output

JSON

  • versions - Array of merge request version objects returned by the API, each representing a version of the merge request.

Dependencies

  • GitLab API authentication credential

Troubleshooting

  • Ensure the project ID and merge request IID are correct and accessible with the provided authentication.
  • Check that the base URL is correct for the GitLab instance being accessed.
  • If pagination parameters are used, verify they are valid integers to avoid request errors.
  • Authentication errors may occur if the API key is missing or invalid; ensure proper credentials are set.

Links

Discussion