GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation interacts with the GitLab API to obtain upload URLs for a Conan package within a specific project. It is useful for automating package management workflows in GitLab, particularly for uploading Conan packages to a project's package registry. For example, it can be used in CI/CD pipelines to programmatically retrieve upload URLs for package versions, facilitating seamless package uploads.

Use Case Examples

  1. Automate retrieval of upload URLs for Conan packages in a GitLab project to streamline package uploads.
  2. Integrate with GitLab's Conan package registry to manage package versions and channels programmatically.

Properties

Name Meaning
Skip Authentication Option to skip API authentication, useful for public endpoints or testing.
baseUrl Base URL of the GitLab instance, defaulting to https://gitlab.com.
Method HTTP method to use for the API request, default is GET with options including POST, PUT, DELETE, HEAD, PATCH.
Path Parameters Parameters required in the API path to specify the project and package details.

Output

JSON

  • upload_urls - The URLs returned by the API for uploading the Conan package files.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure all required path parameters (id, package_name, package_version, package_username, package_channel) are correctly provided and URL-encoded if necessary.
  • Verify that the GitLab API key credential is valid and has sufficient permissions to access the project's package registry.
  • Check the baseUrl if using a self-hosted GitLab instance to ensure it is correct.
  • Common errors include 401 Unauthorized (authentication issues), 404 Not Found (incorrect project or package details), and 400 Bad Request (invalid parameters). Resolving these involves verifying credentials, parameters, and API endpoint correctness.

Links

Discussion