GitLab API

GitlabTool

Actions905

Overview

This node operation allows users to unapprove a specific merge request in a GitLab project. It is useful in scenarios where a previously given approval on a merge request needs to be revoked, such as when changes are requested or the approval was given in error. For example, a developer or project maintainer can use this operation to unapprove a merge request identified by its project ID and merge request IID.

Use Case Examples

  1. Unapprove a merge request with project ID 123 and merge request IID 456 to revoke approval.
  2. Use in automated workflows to manage merge request approvals dynamically based on custom criteria.

Properties

Name Meaning
Skip Authentication Whether to skip authentication for the request.
Authentication The authentication method used, defaulting to GitLab API key authentication.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method The HTTP method to use for the request, defaulting to POST.
Path Parameters The path parameters required to identify the project and merge request to unapprove.

Output

JSON

  • id - The ID of the project.
  • merge_request_iid - The internal ID of the merge request.
  • status - The status of the unapprove operation, typically indicating success or failure.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID and merge request IID are correct and exist in the GitLab instance.
  • Verify that the API key used has sufficient permissions to unapprove merge requests.
  • Check the base URL to ensure it points to the correct GitLab instance.
  • Common error messages may include authentication failures, resource not found, or insufficient permissions. Verify credentials and resource identifiers to resolve these.

Links

Discussion