GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation retrieves details of a specific remote mirror for a given project in GitLab using the GitLab API. It is useful for scenarios where you need to fetch information about a remote mirror associated with a project, such as its status or configuration. For example, it can be used in automation workflows to monitor or manage remote mirrors of GitLab projects.

Use Case Examples

  1. Fetch remote mirror details for a project to check synchronization status.
  2. Automate monitoring of remote mirrors to trigger alerts if a mirror is down.

Properties

Name Meaning
Skip Authentication Determines whether to skip authentication for the API request.
Authentication Specifies the authentication method to use, defaulting to GitLab API authentication.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method The HTTP method to use for the request, defaulting to GET.
Path Parameters Parameters to specify the project ID or URL-encoded path and the remote mirror ID to identify the resource.

Output

JSON

  • id - The ID of the remote mirror.
  • url - The URL of the remote mirror.
  • enabled - Indicates if the remote mirror is enabled.
  • only_protected_branches - Indicates if only protected branches are mirrored.
  • keep_divergent_refs - Indicates if divergent refs are kept.
  • created_at - Timestamp when the remote mirror was created.
  • updated_at - Timestamp when the remote mirror was last updated.
  • last_update_at - Timestamp of the last update attempt.
  • status - Current status of the remote mirror.

Dependencies

  • GitLab API authentication token or credentials

Troubleshooting

  • Ensure the project ID and mirror ID are correctly specified and URL-encoded if necessary.
  • Verify that the authentication token has sufficient permissions to access the project and remote mirror details.
  • Check the base URL to ensure it points to the correct GitLab instance.
  • Common error messages include 404 Not Found if the project or mirror does not exist, and 401 Unauthorized if authentication fails.

Links

Discussion