GitLab API

GitlabTool

Actions1000

Overview

This node operation interacts with the GitLab API to retrieve information about admin clusters via the endpoint `/api/v4/admin/clusters`. It supports making HTTP requests with various methods (GET, POST, PUT, DELETE, HEAD, PATCH) to this endpoint, primarily used for managing or querying cluster data in a GitLab instance. This is useful for administrators who need to automate cluster management or gather cluster-related data programmatically.

Use Case Examples

  1. An admin wants to list all clusters in their GitLab instance automatically.
  2. A DevOps engineer needs to update cluster configurations via API calls within an automation workflow.

Properties

Name Meaning
Skip Authentication Determines whether to skip the authentication process for the API request.
Authentication Specifies the authentication method to use, defaulting to GitLab API key authentication. Hidden if Skip Authentication is true.
baseUrl The base URL of the GitLab instance to which the API requests are sent.
Method The HTTP method to use for the API request (GET, POST, PUT, DELETE, HEAD, PATCH).
Parameter Schema Hidden property for the parameter schema of the operation, not user-editable.
Request Body Schema Hidden property for the request body schema of the operation, not user-editable.
Request Path The API endpoint path for the operation, fixed to `/api/v4/admin/clusters`.

Output

JSON

  • response - The JSON response from the GitLab API containing information about admin clusters.

Dependencies

  • GitLab API key credential for authentication unless Skip Authentication is enabled.

Troubleshooting

  • Ensure the GitLab API key credential is correctly configured and has sufficient permissions to access admin cluster data.
  • If Skip Authentication is enabled, verify that the GitLab instance allows unauthenticated access to the endpoint, otherwise requests will fail.
  • Check the baseUrl property to ensure it points to the correct GitLab instance URL.
  • Common error messages include authentication failures (401 Unauthorized) and permission errors (403 Forbidden), which indicate issues with API credentials or user permissions.

Links

Discussion