GitLab API icon

GitLab API

Gitlab

Actions1062

Merge_requests → putApiV4ProjectsIdMergeRequestsMergeRequestIidResetApprovals

AI-generated

Summary

Reset the approvals for a specific merge request in a GitLab project, clearing any existing approval status.

Inputs

  • id (required) — The ID of the GitLab project containing the merge request.
  • merge_request_iid (required) — The internal ID of the merge request within the project.
  • skipAuthentication — Optional flag to skip authentication for the request; defaults to false.
  • baseUrl — Base URL of the GitLab instance; defaults to 'https://gitlab.com'.

Output shape

a single record representing the status after approvals reset (as returned by GitLab API)

The operation issues a PUT request to the endpoint '/api/v4/projects/{id}/merge_requests/{merge_request_iid}/reset_approvals'. The output matches GitLab's API response for this endpoint. Authentication is required by default unless skipped via 'skipAuthentication'.

Examples

Example 1: Reset approvals on merge request IID 42 in project ID 123

Set 'id' to '123', 'merge_request_iid' to '42', and execute the operation to clear approvals for that merge request.

Links

Discussion