GitLab API

GitlabTool

Actions1000

Overview

This node operation deletes a remote mirror from a specified GitLab project using the GitLab API. It is useful for managing project mirrors by removing outdated or unnecessary remote mirrors. For example, a user can automate the cleanup of remote mirrors in their GitLab projects by specifying the project ID and the mirror ID to delete.

Use Case Examples

  1. Delete a remote mirror from a GitLab project by providing the project ID and the mirror ID.
  2. Automate the removal of remote mirrors in GitLab projects to maintain project repository integrity.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the API request.
Authentication Type of authentication used for the API request, defaulting to GitLab API key.
baseUrl Base URL of the GitLab instance, default is https://gitlab.com.
Method HTTP method to use for the API request, default is GET but DELETE is relevant for this operation.
Path Parameters Parameters required in the API request path, including the project ID and the remote mirror ID to delete.

Output

JSON

  • success - Indicates whether the remote mirror was successfully deleted
  • statusCode - HTTP status code returned from the API request
  • message - Additional message or error information from the API response

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure the project ID and mirror ID are correctly specified and exist in the GitLab instance.
  • Verify that the API key used has sufficient permissions to delete remote mirrors in the project.
  • Check the base URL to ensure it points to the correct GitLab instance.
  • Common error messages include 404 Not Found if the project or mirror does not exist, and 403 Forbidden if the API key lacks permissions.

Links

Discussion