GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node integrates with the GitLab API, specifically supporting the operation to update the Mock CI service settings for a project via a PUT request to the endpoint `/api/v4/projects/{id}/services/mock-ci`. It is useful for automating the configuration of GitLab project services, particularly for CI/CD pipeline mocking scenarios.

Use Case Examples

  1. Automate enabling or updating the Mock CI service for a specific GitLab project by providing the project ID and the desired service configuration in the request body.
  2. Use this node in workflows that manage GitLab project settings programmatically, such as in DevOps automation pipelines.

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 for the GitLab instance, defaulting to https://gitlab.com.
Method The HTTP method to use for the request, defaulting to GET but supporting PUT for this operation.
Path Parameters Parameters to be included in the request path, specifically the project ID for this operation.

Output

JSON

  • response - The JSON response from the GitLab API after updating the Mock CI service settings.

Dependencies

  • Requires GitLab API key credentials for authentication unless skipping authentication is enabled.

Troubleshooting

  • Ensure the project ID path parameter is correctly provided and is a valid integer.
  • Verify that the GitLab API key credentials are correctly configured and have sufficient permissions to update project services.
  • Check the base URL if using a self-hosted GitLab instance instead of the default https://gitlab.com.
  • Common errors include authentication failures (401 Unauthorized) and invalid project ID (404 Not Found). Resolving these involves verifying credentials and project existence.

Links

Discussion