Codebase list ruby-gitlab / upstream/4.8.0 lib / gitlab / client / keys.rb
upstream/4.8.0

Tree @upstream/4.8.0 (Download .tar.gz)

keys.rb @upstream/4.8.0raw · history · blame

# frozen_string_literal: true

class Gitlab::Client
  # Defines methods related to keys.
  # @see https://docs.gitlab.com/ce/api/keys.html
  module Keys
    # Gets information about a key.
    #
    # @example
    #   Gitlab.key(1)
    #
    # @param  [Integer] id The ID of a key.
    # @return [Gitlab::ObjectifiedHash]
    def key(id)
      get("/keys/#{id}")
    end
  end
end