GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation allows importing projects into GitLab from Bitbucket using the GitLab API. It is useful for users who want to migrate or synchronize their Bitbucket repositories into GitLab seamlessly. For example, a developer or team migrating their codebase from Bitbucket to GitLab can use this operation to automate the import process.

Use Case Examples

  1. Import a Bitbucket repository into GitLab by providing the necessary import parameters in the request body.
  2. Automate project migration workflows from Bitbucket to GitLab within an n8n automation.

Properties

Name Meaning
Skip Authentication Determines whether to skip authentication for the API request.
Authentication Specifies the authentication method to use for the API request, defaulting to GitLab API key authentication.
baseUrl The base URL of the GitLab instance to which the request is sent, defaulting to https://gitlab.com.
Method The HTTP method to use for the request, defaulting to GET but can be set to POST, PUT, DELETE, HEAD, or PATCH.
Parameter Schema Defines the schema for the parameters expected in the request body for the import operation.
Request Body Schema Defines the schema for the request body content for the import operation.
Request Path The API endpoint path for the Bitbucket import operation, fixed to /api/v4/import/bitbucket.

Output

JSON

  • id - The unique identifier of the imported project.
  • name - The name of the imported project.
  • path - The repository path of the imported project.
  • import_status - The status of the import process (e.g., 'started', 'finished', 'failed').
  • import_error - Details of any error encountered during the import process.

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure the GitLab API key credential is correctly configured and has sufficient permissions to perform project imports.
  • Verify the baseUrl is correctly set to the GitLab instance URL if using a self-hosted GitLab server.
  • Check that the request body conforms to the expected schema for the Bitbucket import operation to avoid validation errors.
  • Common error messages may include authentication failures, permission denied errors, or invalid request body format. Resolving these typically involves verifying credentials, permissions, and request payload structure.

Links

Discussion