GitLab API

GitlabTool

Actions1000

Overview

This node operation retrieves specific NuGet package details from a GitLab project using the GitLab API. It is useful for developers or DevOps engineers who need to fetch metadata or information about a particular NuGet package version within a GitLab project. For example, it can be used to verify package versions or automate package management workflows.

Use Case Examples

  1. Fetch details of a NuGet package named 'mynugetpkg' with version '1.3.0.17' from a GitLab project identified by its project ID.
  2. Automate retrieval of package metadata for CI/CD pipelines to ensure correct package versions are used.

Properties

Name Meaning
Skip Authentication Option to skip authentication when making the API request.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method HTTP method to use for the request, default is GET. Options include GET, POST, PUT, DELETE, HEAD, PATCH.
Query Parameters Parameters to specify the NuGet package name and version to retrieve.
Path Parameters Parameters to specify the GitLab project ID or URL-encoded path.

Output

JSON

  • package_id - The unique identifier of the NuGet package.
  • package_name - The name of the NuGet package.
  • package_version - The version of the NuGet package.
  • metadata - Additional metadata about the NuGet package, such as description, authors, and dependencies.

Dependencies

  • GitLab API authentication token or credentials

Troubleshooting

  • Ensure the project_id, package_name, and package_version parameters are correctly set and URL-encoded if necessary.
  • Verify that the GitLab API credentials are valid and have sufficient permissions to access the project and package data.
  • Check the baseUrl if using a self-hosted GitLab instance to ensure it is correct.
  • Common error messages include 401 Unauthorized (authentication issues), 404 Not Found (incorrect project or package details), and 400 Bad Request (invalid parameters).

Links

Discussion