GitLab API

GitlabTool

Actions905

Overview

This node operation retrieves a specific Terraform module version from the GitLab Terraform Registry API. It is useful for users who want to programmatically access detailed information about a particular version of a Terraform module hosted on GitLab. For example, DevOps engineers can automate fetching module metadata for infrastructure as code workflows.

Use Case Examples

  1. Fetch details of a Terraform module version by specifying the module namespace, name, system, and version.
  2. Automate retrieval of module version info to integrate with CI/CD pipelines.

Properties

Name Meaning
Skip Authentication Determines whether to skip authentication for the API request.
Authentication Specifies the authentication method to use if not skipping authentication.
baseUrl Base URL for the GitLab instance, defaulting to https://gitlab.com.
Method HTTP method to use for the request, default is GET.
Query Parameters Query parameters for the request, specifically the module_version to specify which version of the module to retrieve.
Path Parameters Path parameters required to identify the module: module_namespace (group ID or slug), module_name, and module_system.

Output

JSON

  • module_namespace - The namespace or group ID of the Terraform module.
  • module_name - The name of the Terraform module.
  • module_system - The system type of the module.
  • module_version - The specific version of the Terraform module retrieved.
  • module_details - Detailed information about the requested Terraform module version returned by the API.

Dependencies

  • GitLab API authentication token

Troubleshooting

  • Ensure the module_namespace, module_name, module_system, and module_version parameters are correctly specified; missing or incorrect values will cause API errors.
  • If authentication is enabled, verify that the GitLab API token is valid and has sufficient permissions to access the Terraform Registry.
  • Check the baseUrl if using a self-hosted GitLab instance to ensure the URL is correct.
  • Common error messages include 404 Not Found if the module or version does not exist, and 401 Unauthorized if authentication fails.

Links

Discussion