GitLab API

GitlabTool

Actions1000

Overview

This node operation retrieves detailed information about a specific user from the GitLab API (version 4) by their user ID. It is useful for scenarios where you need to fetch user details such as profile information, custom attributes, or other user-specific data from a GitLab instance. For example, it can be used in automation workflows to get user data for reporting, auditing, or integration with other systems.

Use Case Examples

  1. Fetch user details by providing the user ID to automate user management tasks.
  2. Retrieve custom attributes of a user to sync with an external database.

Properties

Name Meaning
Skip Authentication Determines whether to skip authentication for the API request.
Authentication Specifies the authentication method to use, defaulting to GitLab API key authentication.
baseUrl The base URL of the GitLab instance to which the API request is sent.
Method The HTTP method used for the API request, defaulting to GET.
Query Parameters Optional query parameters for the API request, such as including custom attributes in the response.
Path Parameters Path parameters required for the API request, specifically the user ID to identify which user to retrieve.

Output

JSON

  • id - The unique identifier of the user.
  • username - The username of the user.
  • name - The full name of the user.
  • state - The state of the user account (e.g., active, blocked).
  • avatar_url - URL to the user's avatar image.
  • web_url - URL to the user's GitLab profile page.
  • created_at - Timestamp when the user was created.
  • bio - The user's biography or description.
  • location - The user's location.
  • public_email - The user's public email address.
  • skype - The user's Skype contact.
  • linkedin - The user's LinkedIn profile URL.
  • twitter - The user's Twitter handle.
  • website_url - The user's personal or professional website URL.
  • organization - The organization the user belongs to.
  • last_sign_in_at - Timestamp of the user's last sign-in.
  • confirmed_at - Timestamp when the user was confirmed.
  • last_activity_on - Date of the user's last activity.
  • email - The user's email address.
  • theme_id - The theme ID set by the user.
  • color_scheme_id - The color scheme ID set by the user.
  • projects_limit - The maximum number of projects the user can create.
  • current_sign_in_at - Timestamp of the user's current sign-in.
  • identities - External identities linked to the user.
  • can_create_group - Indicates if the user can create groups.
  • can_create_project - Indicates if the user can create projects.
  • two_factor_enabled - Indicates if two-factor authentication is enabled for the user.
  • external - Indicates if the user is an external user.
  • private_profile - Indicates if the user's profile is private.
  • is_admin - Indicates if the user has admin privileges.

Dependencies

  • An API key credential for GitLab authentication

Troubleshooting

  • Ensure the user ID provided in the path parameters is valid and exists in the GitLab instance to avoid 'User not found' errors.
  • If authentication is enabled, verify that the API key credential is correctly configured and has sufficient permissions to access user data.
  • Check the base URL to ensure it points to the correct GitLab instance, especially if using a self-hosted GitLab server.
  • If the 'with_custom_attributes' query parameter is used, ensure the user has custom attributes set; otherwise, the response may not include them.

Links

Discussion