GitLab API

GitlabTool

Actions1000

Overview

This node operation allows revoking a GPG key for a specific user in GitLab by making a POST request to the GitLab API endpoint `/api/v4/users/{id}/gpg_keys/{key_id}/revoke`. It is useful for managing user security by invalidating GPG keys that should no longer be trusted or used.

Use Case Examples

  1. Revoking a compromised GPG key for a user to prevent its further use.
  2. Automating the management of user GPG keys in an organization's GitLab instance.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request.
baseUrl The base URL of the GitLab instance, defaulting to https://gitlab.com.
Method HTTP method to use for the request, default is GET but POST is used for this operation.
Path Parameters Parameters for the API path including user ID and GPG key ID to specify which key to revoke.

Output

JSON

  • success - Indicates if the GPG key revocation was successful.
  • message - Additional message or details about the revocation result.

Dependencies

  • GitLab API authentication token or credentials

Troubleshooting

  • Ensure the user ID and GPG key ID are correct and exist in the GitLab instance.
  • Verify that the API token used has sufficient permissions to revoke GPG keys.
  • Check the base URL to ensure it points to the correct GitLab instance.
  • Common error messages include 404 Not Found if the user or key does not exist, and 401 Unauthorized if authentication fails.

Links

Discussion