GitLab API

GitlabTool

Actions905

Overview

This node operation retrieves access tokens for a specific project in GitLab using the GitLab API v4. It is useful for managing and auditing project access tokens, filtering them by their state (active or inactive). For example, a user can fetch all active access tokens for a project to review current access permissions.

Use Case Examples

  1. Fetch all active access tokens for a project with a given project ID.
  2. Retrieve inactive access tokens to identify tokens that may need to be revoked or cleaned up.

Properties

Name Meaning
Skip Authentication If set to true, the node will skip using authentication for the request.
Authentication The authentication method used for the request, defaulting to GitLab API authentication.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method The HTTP method used for the request, defaulting to GET.
Query Parameters Optional query parameters to filter the access tokens, such as filtering by state (active or inactive).
Path Parameters Path parameters required for the request, specifically the project ID or URL-encoded path of the project.

Output

JSON

  • ``
    • id - The unique identifier of each access token.
    • name - The name of the access token.
    • state - The state of the access token, e.g., active or inactive.
    • created_at - The creation timestamp of the access token.
    • scopes - The scopes or permissions granted to the access token.

Dependencies

  • GitLab API credentials for authentication

Troubleshooting

  • Ensure the project ID provided in the path parameters is correct and URL-encoded if necessary.
  • Verify that the GitLab API credentials are valid and have sufficient permissions to access project access tokens.
  • If filtering by state, ensure the state value is either 'active' or 'inactive' as per the API specification.
  • Check the base URL if using a self-hosted GitLab instance to ensure it is correct.

Links

Discussion