GitLab API

GitlabTool

Actions1095

User → postApiV4UserGpgKeys

AI-generated

Summary

Add a new GPG key to the authenticated GitLab user's account by sending a POST request to the /api/v4/user/gpg_keys endpoint.

Inputs

  • Skip Authentication — If set to true, the node will skip using authentication credentials.
  • baseUrl — Base URL of the GitLab instance, defaults to https://gitlab.com.
  • Method (required) — HTTP method to use, must be POST for this operation.
  • postApiV4UserGpgKeys (required) — Request body containing the GPG key data to be added to the user account, following the postApiV4UserGpgKeys schema specified by GitLab API.

Output shape

a single JSON object representing the newly added GPG key.

The response shape corresponds to the GitLab API's POST /user/gpg_keys endpoint. Authentication credentials are required unless 'Skip Authentication' is true. The base URL can be overridden, but defaults to https://gitlab.com.

Links

Discussion