GitLab API

GitlabTool

Actions905

Overview

This node interacts with the GitLab API to perform operations related to user runners, specifically allowing the creation of user runners via a POST request to the /api/v4/user/runners endpoint. It is useful for automating the management of GitLab CI/CD runners associated with a user, such as registering new runners programmatically.

Use Case Examples

  1. Automatically register a new GitLab runner for a user when a new project is created.
  2. Manage user runners in GitLab by creating them through an automated workflow.

Properties

Name Meaning
Skip Authentication Determines whether to skip the authentication step 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 API requests are sent, defaulting to https://gitlab.com.
Method The HTTP method to use for the API request, defaulting to GET but supporting POST, PUT, DELETE, HEAD, and PATCH.
Parameter Schema Defines the schema for the parameters sent in the request body for the postApiV4UserRunners operation.
Request Body Schema Defines the schema for the request body for the postApiV4UserRunners operation.
Request Path The API endpoint path for the postApiV4UserRunners operation, fixed to /api/v4/user/runners.

Output

JSON

  • response - The JSON response from the GitLab API after creating a user runner, containing details about the newly created runner.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the GitLab API key credential is correctly configured and has the necessary permissions to create user runners.
  • Verify the baseUrl is correct and accessible, especially if using a self-hosted GitLab instance.
  • Check that the request body matches the expected schema for creating a user runner to avoid validation errors.

Links

Discussion