GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation allows users to add or manage a user cluster within a specific GitLab project by making a POST request to the GitLab API endpoint `/api/v4/projects/{id}/clusters/user`. It is useful for automating cluster user management in GitLab projects, such as adding a user to a cluster for deployment or access purposes.

Use Case Examples

  1. Automate adding a user to a Kubernetes cluster in a GitLab project.
  2. Manage cluster user access programmatically for multiple projects.

Properties

Name Meaning
Skip Authentication Option to skip API authentication for the 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 request, default is GET but POST is used for this operation.
Path Parameters Parameters to be included in the request path, specifically the project ID or URL-encoded path.

Output

JSON

  • id - The ID of the project for which the cluster user is being managed.
  • clusterUserDetails - Details of the user added or managed in the cluster (based on API response).

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure the project ID provided in path parameters is correct and accessible.
  • Verify that the GitLab API key has sufficient permissions to manage cluster users.
  • Check the base URL if using a self-hosted GitLab instance instead of gitlab.com.
  • Common errors include authentication failures, invalid project ID, or insufficient permissions.

Links

Discussion