GitLab API

GitlabTool

Actions905

Overview

This node interacts with the GitLab API to perform operations related to NPM packages within a GitLab project. Specifically, the operation 'postApiV4ProjectsIdPackagesNpmNpmV1SecurityAdvisoriesBulk' allows users to bulk post security advisories for NPM packages in a specified project. This is useful for automating security management and vulnerability reporting in software projects hosted on GitLab.

Use Case Examples

  1. Automatically submit multiple security advisories for NPM packages in a GitLab project to keep dependencies secure.
  2. Integrate with CI/CD pipelines to update security advisories in bulk after scanning project dependencies.

Properties

Name Meaning
Skip Authentication Option to bypass authentication for the request, useful for public endpoints or testing.
Authentication Specifies the authentication method to use, defaulting to GitLab API key authentication.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method HTTP method to use for the request, default is GET but POST is used for the bulk security advisories operation.
Path Parameters Parameters to specify the project ID or URL-encoded path for the API endpoint.

Output

JSON

  • response - The JSON response from the GitLab API after posting bulk security advisories, typically containing status and details of the advisories processed.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID provided in path parameters is correct and accessible with the authenticated user.
  • Verify that the GitLab API key has sufficient permissions to post security advisories.
  • Check the baseUrl if using a self-hosted GitLab instance to ensure it is correct.
  • Common errors include authentication failures (401 Unauthorized) and invalid project ID (404 Not Found).
  • If the request body schema is incorrect or missing required fields, the API may return a 400 Bad Request error.

Links

Discussion