GitLab API

GitlabTool

Actions1000

Overview

This node operation retrieves artifacts for a specific job from the GitLab API (version 4). It is useful for scenarios where you need to download or access job artifacts generated during CI/CD pipelines in GitLab. For example, you can use this node to fetch build outputs, test results, or deployment packages associated with a particular job ID.

Use Case Examples

  1. Downloading build artifacts for a job to use in subsequent workflow steps.
  2. Accessing test reports generated by a CI job for analysis or reporting.

Properties

Name Meaning
Skip Authentication Option to skip authentication when making the API request.
Authentication Type of authentication used for the API request, defaulting to GitLab API key authentication.
baseUrl Base URL of the GitLab instance to which the API request is sent.
Method HTTP method used for the API request, default is GET.
Query Parameters Optional query parameters for the API request, including token for job authentication and direct_download to specify if artifacts should be downloaded directly from remote storage.
Path Parameters Path parameters for the API request, specifically the job ID to identify which job's artifacts to retrieve.

Output

JSON

  • artifacts - The artifacts data retrieved from the specified job in GitLab

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure the job ID provided in the path parameters is valid and exists in the GitLab project.
  • If authentication is enabled, verify that the API key credential is correctly configured and has sufficient permissions to access job artifacts.
  • Check the baseUrl to ensure it points to the correct GitLab instance, especially if using a self-hosted GitLab server.
  • If using the token query parameter, ensure it is the correct job authentication token to avoid authorization errors.

Links

Discussion