GitLab API

GitlabTool

Actions905

Overview

This node operation retrieves NuGet packages from a specific GitLab project using the GitLab API v4. It is useful for developers or DevOps engineers who want to query NuGet packages associated with a project, filter results by search terms, control pagination, and include prerelease versions if needed. For example, it can be used to list all NuGet packages in a project or search for a specific package by name.

Use Case Examples

  1. Query NuGet packages in a project by project ID.
  2. Search for NuGet packages matching a search term within a project.
  3. Paginate through NuGet package results by skipping and limiting the number of returned items.
  4. Include or exclude prerelease versions in the query results.

Properties

Name Meaning
Skip Authentication Whether to skip authentication for the API request.
Authentication The authentication method used for the API request, defaulting to GitLab API authentication.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method The HTTP method used for the API request, defaulting to GET.
Parameter Schema Defines the parameters for the API request including project ID, search term, pagination, and prerelease inclusion.
Query Parameters Collection of query parameters to filter and paginate the NuGet packages, including search term (q), skip, take, and prerelease flags.
Path Parameters Collection of path parameters specifying the project ID for the API request.

Output

JSON

  • id - The unique identifier of the NuGet package.
  • name - The name of the NuGet package.
  • version - The version of the NuGet package.
  • description - Description of the NuGet package.
  • created_at - Timestamp when the package was created.
  • updated_at - Timestamp when the package was last updated.
  • prerelease - Boolean indicating if the package version is a prerelease.

Dependencies

  • GitLab API authentication token or credentials

Troubleshooting

  • Ensure the project ID is correctly specified and URL-encoded if necessary.
  • Verify that the authentication token has sufficient permissions to access the project's packages.
  • Check the base URL if using a self-hosted GitLab instance instead of gitlab.com.
  • Handle pagination parameters correctly to avoid missing or duplicating results.
  • If the API returns errors, verify the query parameters and request path for correctness.

Links

Discussion