GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation retrieves specific Conan package files from a GitLab project using the GitLab API. It is useful for developers and DevOps engineers who need to access package files such as conanfile.py, conanmanifest.txt, or conaninfo.txt for managing Conan packages stored in GitLab. For example, it can be used to automate the retrieval of package metadata or source files during a CI/CD pipeline.

Use Case Examples

  1. Fetching the conaninfo.txt file of a specific Conan package version to verify package details.
  2. Downloading the conanfile.py recipe to inspect or modify the package build instructions.

Properties

Name Meaning
Skip Authentication Whether to skip authentication for the API request.
Authentication The authentication method used for the API request, typically an API key credential.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method The HTTP method used for the request, default is GET.
Path Parameters Parameters required in the API path to specify the project and Conan package details.

Output

JSON

  • fileContent - The content of the requested Conan package file.
  • fileName - The name of the retrieved file.
  • projectId - The ID or path of the GitLab project.
  • packageName - The name of the Conan package.
  • packageVersion - The version of the Conan package.

Dependencies

  • GitLab API authentication token or API key credential

Troubleshooting

  • Ensure all required path parameters are correctly provided and URL-encoded if necessary.
  • Verify that the authentication token has sufficient permissions to access the project and packages.
  • Check that the specified file name is one of the allowed values (e.g., conanfile.py, conaninfo.txt).
  • Common errors include 404 Not Found if the project or package does not exist, or 401 Unauthorized if authentication fails.

Links

Discussion