GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation retrieves details of a specific deployment within a GitLab project using the GitLab API. It is useful for scenarios where you need to fetch deployment information such as status, environment, or timestamps for a given project and deployment ID. For example, it can be used in CI/CD pipelines to monitor deployment progress or audit deployment history.

Use Case Examples

  1. Fetch deployment details for project ID '123' and deployment ID '456' to monitor deployment status.
  2. Retrieve deployment metadata for a specific project to trigger notifications or further automation steps.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request, useful for public or unauthenticated endpoints.
Authentication Type of authentication used, defaulting to GitLab API key authentication.
baseUrl Base URL of the GitLab instance, defaulting to https://gitlab.com.
Method HTTP method to use for the request, default is GET.
Path Parameters Parameters to specify the project ID and deployment ID for the API request.

Output

JSON

  • id - The unique identifier of the deployment.
  • iid - Internal ID of the deployment within the project.
  • ref - The Git reference (branch or tag) associated with the deployment.
  • sha - The commit SHA associated with the deployment.
  • created_at - Timestamp when the deployment was created.
  • updated_at - Timestamp when the deployment was last updated.
  • status - Current status of the deployment (e.g., success, failed, running).
  • environment - The environment to which the deployment was made (e.g., production, staging).
  • deployable - Details about the deployable job associated with the deployment.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID and deployment ID are correct and accessible by the authenticated user to avoid 404 errors.
  • If authentication is skipped, verify that the endpoint supports unauthenticated access, otherwise requests will fail.
  • Check that the base URL is correctly set to the GitLab instance you are targeting, especially if using a self-hosted GitLab.
  • Common error messages include '404 Not Found' if the deployment or project does not exist, and '401 Unauthorized' if authentication fails. Verify credentials and permissions.

Links

Discussion