GitLab API

GitlabTool

Actions905

Overview

This node operation retrieves specific Terraform module information from a GitLab project using the GitLab API. It is useful for users who want to programmatically access details about Terraform modules stored in GitLab, such as module versions and system types. For example, it can be used in automation workflows to fetch module metadata for infrastructure as code management.

Use Case Examples

  1. Fetch Terraform module details for a given project ID, module name, and system type to verify module versions before deployment.
  2. Automate retrieval of Terraform module metadata to integrate with CI/CD pipelines for infrastructure provisioning.

Properties

Name Meaning
Skip Authentication Option to bypass authentication for the request.
Authentication Type of authentication used, 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.
Parameter Schema Defines required path and query parameters for the API call, including project ID, module name, module system, module version, and optional terraform-get flag.
Query Parameters Collection of query parameters including module_version and terraform-get flag.
Path Parameters Collection of path parameters including project ID, module name, and module system.

Output

JSON

  • id - The ID or full path of the project.
  • module_name - Name of the Terraform module.
  • module_system - System type of the module (e.g., aws).
  • module_version - Version of the Terraform module.
  • terraform-get - Optional flag for Terraform get redirection.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID, module name, module system, and module version are correctly specified to avoid 404 errors.
  • If authentication is enabled, verify that the GitLab API key is valid and has sufficient permissions.
  • Check the baseUrl if using a self-hosted GitLab instance to ensure the URL is correct.

Links

Discussion