GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation allows importing a group into GitLab via the GitLab API. It is useful for automating the process of importing group data from an export file into a GitLab instance, including specifying group path, name, and optionally the parent group or organization. Practical examples include migrating groups between GitLab instances or restoring group data from backups.

Use Case Examples

  1. Import a group export file to create a new group in GitLab with a specified path and name.
  2. Import a group into a specific parent group or organization by providing the respective IDs.

Properties

Name Meaning
Skip Authentication Whether to skip authentication for the request.
Authentication The authentication method used for the request, typically an API key credential.
baseUrl The base URL of the GitLab instance to which the request is sent.
Method The HTTP method used for the request, default is GET but POST is used for this operation.
Parameter Schema Defines the parameters required for the group import operation, including group path, name, file to import, optional parent group ID, and optional organization ID.
Request Body Schema Schema for the request body, not explicitly defined here but implied by the parameters.
Request Path The API endpoint path for the group import operation, fixed as /api/v4/groups/import.

Output

JSON

  • id - The unique identifier of the imported group.
  • name - The name of the imported group.
  • path - The path of the imported group.
  • parent_id - The ID of the parent group if specified.
  • organization_id - The ID of the organization the group belongs to if specified.
  • import_status - Status of the import operation.

Dependencies

  • GitLab API authentication token or API key credential

Troubleshooting

  • Ensure the group export file is correctly formatted and accessible for upload.
  • Verify that the provided group path and name are unique and valid within the GitLab instance.
  • Check that the parent_id and organization_id, if provided, exist and the authenticated user has permission to import into them.
  • Authentication errors may occur if the API key or token is invalid or missing; ensure proper credentials are configured.

Links

Discussion