GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation retrieves environment details for a specific project in GitLab using the GitLab API. It is useful for users who want to fetch information about deployment environments associated with a project, such as available, stopping, or stopped environments. Practical examples include automating environment monitoring, integrating environment data into dashboards, or managing deployment workflows.

Use Case Examples

  1. Fetch all environments for a project by project ID.
  2. Search for environments by name or partial match within a project.
  3. Filter environments by their state (available, stopping, stopped) for a project.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request.
Authentication Type of authentication used, defaulting to GitLab API key.
baseUrl Base URL of the GitLab instance, default is https://gitlab.com.
Method HTTP method to use for the request, default is GET.
Query Parameters Optional query parameters to filter or paginate the environments list.
Path Parameters Path parameter specifying the project ID or URL-encoded path.

Output

JSON

  • id - Unique identifier of the environment.
  • name - Name of the environment.
  • state - Current state of the environment (available, stopping, stopped).
  • external_url - External URL associated with the environment.
  • updated_at - Timestamp of the last update to the environment.

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure the project ID or path is correct and accessible by the authenticated user to avoid authorization errors.
  • Verify that the base URL is correct and reachable, especially if using a self-hosted GitLab instance.
  • Check that query parameters like 'name' and 'search' are used exclusively as they are mutually exclusive.
  • If no environments are returned, confirm that the project has environments configured and that the filters applied are valid.

Links

Discussion