GitLab API

GitlabTool

Actions905

Overview

This node operation retrieves specific Conan package files from a GitLab repository using the GitLab API. It is designed to fetch files related to Conan packages, such as conanfile.py, conanmanifest.txt, or conan_package.tgz, by specifying detailed path parameters including package name, version, username, channel, recipe revision, and file name. This is useful for developers or CI/CD pipelines that need to programmatically access Conan package files stored in GitLab for automation, auditing, or deployment purposes.

Use Case Examples

  1. Fetching the 'conanfile.py' for a specific Conan package version to inspect its build instructions.
  2. Downloading the 'conan_package.tgz' file for deployment or testing in a build pipeline.

Properties

Name Meaning
Skip Authentication Whether to skip authentication when making the API request.
Authentication The authentication method used for the API request, defaulting to GitLab API key authentication.
baseUrl The base URL of the GitLab instance to which the API request is sent.
Method The HTTP method used for the API request, default is GET.
pathParameters.package_name The name of the Conan package to retrieve.
pathParameters.package_version The version of the Conan package.
pathParameters.package_username The username or group/project owning the package.
pathParameters.package_channel The channel of the Conan package (e.g., stable).
pathParameters.recipe_revision The revision number of the Conan recipe.
pathParameters.file_name The specific file name to retrieve from the Conan package, restricted to known Conan package files.

Output

JSON

  • data - The content or metadata of the requested Conan package file retrieved from GitLab.

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure all required path parameters are correctly provided and match the package details in GitLab to avoid 404 errors.
  • If authentication is enabled, verify that the GitLab API key credential is valid and has sufficient permissions to access the package files.
  • Check the baseUrl if using a self-hosted GitLab instance to ensure the API endpoint is reachable.
  • Common error messages include '404 Not Found' if the package or file does not exist, and '401 Unauthorized' if authentication fails.

Links

Discussion