GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation deletes a specific cluster agent from a GitLab project using the GitLab API. It is useful for managing and cleaning up cluster agents associated with projects, especially in DevOps workflows where cluster agents are used for Kubernetes cluster management. For example, if a cluster agent is no longer needed or needs to be replaced, this operation can remove it programmatically.

Use Case Examples

  1. Deleting a cluster agent from a project to revoke its access or clean up resources.
  2. Automating cluster agent management in CI/CD pipelines.

Properties

Name Meaning
Skip Authentication Determines whether to skip authentication for the API request.
Authentication Specifies the authentication method to use, 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 DELETE for this operation.
Path Parameters Parameters required in the request path to identify the project and the cluster agent to delete.

Output

JSON

  • success - Indicates whether the cluster agent was successfully deleted.
  • statusCode - HTTP status code returned by the API.
  • message - Additional message or details about the deletion operation.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

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

Links

Discussion