Class: PlatformAPI::Key

Inherits:
Object
  • Object
show all
Defined in:
lib/platform-api/client.rb

Overview

Keys represent public SSH keys associated with an account and are used to authorize accounts as they are performing git operations.

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ Key

Returns a new instance of Key.



2044
2045
2046
# File 'lib/platform-api/client.rb', line 2044

def initialize(client)
  @client = client
end

Instance Method Details

#info(key_id_or_key_fingerprint) ⇒ Object

Info for existing key.

Parameters:

  • key_id_or_key_fingerprint:

    unique identifier of this key or a unique identifying string based on contents



2051
2052
2053
# File 'lib/platform-api/client.rb', line 2051

def info(key_id_or_key_fingerprint)
  @client.key.info(key_id_or_key_fingerprint)
end

#listObject

List existing keys.



2056
2057
2058
# File 'lib/platform-api/client.rb', line 2056

def list()
  @client.key.list()
end