GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation retrieves the raw content of a specific blob (file) from a GitLab project's repository using the GitLab API v4. It is useful for scenarios where you need to access the exact file content at a particular commit hash, such as fetching source code files, configuration files, or any repository data programmatically.

Use Case Examples

  1. Fetching the raw content of a configuration file at a specific commit to use in a deployment pipeline.
  2. Retrieving source code files from a GitLab repository for analysis or processing in an automation workflow.

Properties

Name Meaning
Skip Authentication If set to true, the node will skip using authentication for the API request.
Authentication The authentication method used for the API request, typically an API key credential for GitLab.
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 used in the request path to specify the project and blob to retrieve.

Output

JSON

  • raw - The raw content of the blob (file) retrieved from the GitLab repository at the specified commit hash.

Dependencies

  • GitLab API authentication credential

Troubleshooting

  • Ensure the project ID and commit SHA are correct and URL-encoded if necessary.
  • Authentication errors may occur if the API key is missing or invalid; verify credentials.
  • Permission errors can happen if the API token does not have access to the project repository.
  • Network or base URL misconfiguration can cause request failures; check the baseUrl setting.

Links

Discussion