GitLab API icon

GitLab API

Gitlab

Actions1062

Users → getApiV4UsersUserIdKeys

AI-generated

Summary

Fetches the SSH public keys for a specified GitLab user.

Inputs

  • user_id (required) — The ID or username of the user whose SSH keys are retrieved.
  • page — Current page number for paginated results (default: 1).
  • per_page — Number of keys to return per page (default: 20).
  • skipAuthentication — If true, the request runs without credentials (default: false).

Output shape

array

Each element is a GitLab SSH key object containing fields such as id, key, title, created_at.

Examples

Example 1: Get keys for user with username 'alice'

Set user_id=alice, leave page/per_page defaults, keep skipAuthentication false.

Links

Discussion