GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation allows users to register a runner to a specific GitLab project by making a POST request to the GitLab API endpoint `/api/v4/projects/{id}/runners`. It is useful for automating the management of CI/CD runners associated with projects, enabling continuous integration workflows to be dynamically configured or updated.

Use Case Examples

  1. Automatically add a new runner to a project when setting up CI/CD pipelines.
  2. Manage runners programmatically for multiple projects in GitLab to streamline DevOps processes.

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 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 used for the request, defaulting to POST for this operation.
Path Parameters Collection of path parameters required for the request, specifically the project ID or URL-encoded path.

Output

JSON

  • id - The ID or URL-encoded path of the project to which the runner is being added.
  • runner - Details of the runner registered to the project, as returned by the GitLab API.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID provided in the path parameters is correct and accessible by the authenticated user.
  • Verify that the GitLab API key credential has sufficient permissions to register runners to the project.
  • Check the base URL if using a self-hosted GitLab instance to ensure the request is sent to the correct endpoint.
  • Common error messages include authentication failures (401 Unauthorized) and resource not found (404 Not Found) if the project ID is invalid or inaccessible.

Links

Discussion