GitLab API

GitlabTool

Actions1000

Overview

This node operation allows importing members from one GitLab project to another by making a POST request to the GitLab API endpoint `/api/v4/projects/{id}/import_project_members/{project_id}`. It is useful for scenarios where you want to replicate or transfer project members from a source project to a target project within GitLab, such as when setting up a new project with the same team members as an existing one.

Use Case Examples

  1. Import members from a source project to a new project to maintain consistent team access.
  2. Automate member synchronization between related projects in GitLab.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request, useful for public or unauthenticated API access.
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, defaulting to GET but POST is used for this operation.
Path Parameters Parameters to specify the target project ID (`id`) and the source project ID (`project_id`) for importing members.

Output

JSON

  • id - The ID of the target project where members are imported.
  • project_id - The ID of the source project from which members are imported.
  • status - Status of the import operation, indicating success or failure.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the provided project IDs are correct and accessible with the authenticated user.
  • Verify that the authentication token has sufficient permissions to import project members.
  • Check the base URL if using a self-hosted GitLab instance to ensure it is correct.
  • Common error messages include 404 Not Found if project IDs are invalid or inaccessible, and 403 Forbidden if authentication lacks required permissions.

Links

Discussion