GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation retrieves details of a specific cluster agent within a GitLab project using the GitLab API. It is useful for DevOps and development teams managing Kubernetes clusters linked to GitLab projects, allowing them to fetch agent information programmatically. For example, it can be used to monitor or audit cluster agents associated with a project.

Use Case Examples

  1. Fetch details of a cluster agent by providing the project ID and agent ID to integrate cluster management into CI/CD pipelines.
  2. Automate retrieval of cluster agent information for reporting or monitoring purposes.

Properties

Name Meaning
Skip Authentication Option to skip API authentication, useful for public or unauthenticated requests.
Authentication Type of authentication used, defaulting to GitLab API key authentication.
baseUrl Base URL of the GitLab instance, defaulting to https://gitlab.com.
Method HTTP method to use for the request, default is GET.
Path Parameters Parameters to specify the project ID and cluster agent ID for the API request.

Output

JSON

  • id - The unique identifier of the cluster agent.
  • name - The name of the cluster agent.
  • web_url - The URL to access the cluster agent in GitLab.
  • created_at - Timestamp when the cluster agent was created.
  • updated_at - Timestamp when the cluster agent was last updated.
  • config - Configuration details of the cluster agent.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID and agent ID are correctly provided and URL-encoded if necessary.
  • Verify that the GitLab API key has sufficient permissions to access cluster agent details.
  • Check the base URL if using a self-hosted GitLab instance to ensure it is correct.
  • Common error messages include 404 Not Found if the project or agent does not exist, and 401 Unauthorized if authentication fails.

Links

Discussion