GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation updates the state of a specific user within a GitLab group by making a PUT request to the GitLab API endpoint `/api/v4/groups/{id}/members/{user_id}/state`. It is useful for managing group membership states, such as activating or deactivating a user's membership in a group. Practical examples include automating user access control in GitLab groups or synchronizing group membership states based on external systems.

Use Case Examples

  1. Automatically deactivate a user in a GitLab group when they leave an organization.
  2. Activate a user in a GitLab group as part of an onboarding workflow.

Properties

Name Meaning
Skip Authentication Option to skip API authentication for the request.
Authentication The authentication method used for the API request, 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 PUT.
Path Parameters Parameters included in the API request path to specify the group ID and user ID whose membership state is being updated.

Output

JSON

  • id - The ID of the group member whose state was updated.
  • user_id - The user ID of the member whose state was updated.
  • state - The new state of the user membership in the group.

Dependencies

  • GitLab API key credential

Troubleshooting

  • Ensure the group ID and user ID path parameters are correctly set and valid to avoid 404 Not Found errors.
  • Verify that the API key used for authentication has sufficient permissions to update group membership states to prevent authorization errors.
  • Check the request body schema for correctness to avoid validation errors from the API.

Links

Discussion