GitLab API

GitlabTool

Actions1000

Overview

This node operation fetches merge requests from the GitLab API (version 4) based on various query parameters. It is useful for retrieving detailed information about merge requests in a GitLab project, such as filtering by author, assignee, state, labels, milestones, and other criteria. Practical examples include listing all open merge requests assigned to a specific user, or searching merge requests created after a certain date.

Use Case Examples

  1. Retrieve all open merge requests assigned to the authenticated user.
  2. Search merge requests created by a specific author within a date range.

Properties

Name Meaning
Skip Authentication Whether to skip authentication for the API request.
baseUrl The base URL of the GitLab instance to query.
Method HTTP method to use for the API request (GET, POST, PUT, DELETE, HEAD, PATCH).
Query Parameters Collection of query parameters to filter and customize the merge requests retrieval.

Output

JSON

  • id - Unique identifier of the merge request.
  • iid - Internal ID of the merge request within the project.
  • project_id - ID of the project the merge request belongs to.
  • title - Title of the merge request.
  • description - Description of the merge request.
  • state - Current state of the merge request (opened, closed, merged, etc.).
  • created_at - Timestamp when the merge request was created.
  • updated_at - Timestamp when the merge request was last updated.
  • merged_at - Timestamp when the merge request was merged, if applicable.
  • closed_at - Timestamp when the merge request was closed, if applicable.
  • author - Information about the author of the merge request.
  • assignee - Information about the assignee of the merge request.
  • labels - Labels associated with the merge request.
  • milestone - Milestone associated with the merge request.
  • merge_status - Current merge status of the merge request.
  • web_url - URL to view the merge request in GitLab.

Dependencies

  • GitLab API authentication (API key or token)

Troubleshooting

  • Ensure the GitLab API credentials are correctly configured and have sufficient permissions to access merge requests.
  • Verify the base URL is correct for the GitLab instance being queried.
  • Check that query parameters are valid and correctly formatted according to GitLab API documentation.
  • Common error messages include authentication failures, invalid query parameters, or rate limiting by the GitLab API. Resolving these involves correcting credentials, adjusting parameters, or handling API rate limits.

Links

Discussion