GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation performs a HEAD request to the GitLab API endpoint that retrieves blame information for a specific file in a project's repository. It is useful for scenarios where you want to check metadata or existence of blame data for a file without downloading the full content. For example, it can be used to verify if blame information is available for a file at a certain commit, branch, or tag in a GitLab project repository.

Use Case Examples

  1. Checking if blame information exists for a file before processing it further.
  2. Verifying file metadata in a CI/CD pipeline to trigger conditional workflows based on file changes.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request.
Authentication Type of authentication used, default is GitLab API key.
baseUrl Base URL of the GitLab instance, default is https://gitlab.com.
Method HTTP method to use for the request, default is GET but HEAD is used for this operation.
Query Parameters Query parameters for the request, specifically the 'ref' which is the name of the branch, tag, or commit.
Path Parameters Path parameters for the request including the project ID and the URL encoded file path.

Output

JSON

  • headers - HTTP response headers from the HEAD request.
  • statusCode - HTTP status code of the response.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID and file path are correctly URL encoded and valid.
  • Verify that the 'ref' query parameter corresponds to an existing branch, tag, or commit in the repository.
  • Authentication errors may occur if the API key is missing or invalid; ensure proper credentials are configured.
  • HEAD requests do not return a response body; check the response headers and status code for information.

Links

Discussion