GitLab API icon

GitLab API

Gitlab

Actions917

Overview

This node operation allows users to create draft notes on a specific merge request within a GitLab project. It is useful for developers and teams who want to add comments or feedback on merge requests without immediately publishing them as official notes. For example, a developer can use this node to save draft comments while reviewing code changes before finalizing and submitting them.

Use Case Examples

  1. Creating a draft note on a merge request to provide feedback during code review.
  2. Adding private comments to a merge request that can be edited before being made public.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request.
Authentication Type of authentication used, default is GitLab API key.
baseUrl The base URL of the GitLab instance, default is https://gitlab.com.
Method HTTP method to use for the request, default is GET.
Path Parameters Parameters required in the URL path to identify the project and merge request.

Output

JSON

  • id - The unique identifier of the created draft note.
  • body - The content of the draft note.
  • author
    • id - The ID of the user who created the draft note.
  • created_at - Timestamp when the draft note was created.
  • updated_at - Timestamp when the draft note was last updated.

Dependencies

  • Requires GitLab API key credential for authentication.

Troubleshooting

  • Ensure the project ID and merge request IID are correct and exist in the GitLab instance.
  • Verify that the authentication credentials are valid and have sufficient permissions to create draft notes.
  • Check the base URL to ensure it points to the correct GitLab instance.
  • Common error messages include 401 Unauthorized (invalid credentials), 404 Not Found (invalid project or merge request ID), and 400 Bad Request (invalid request body). Resolving these involves correcting credentials, IDs, or request data.

Links

Discussion