Module: Dnsimple::Client::Identity

Included in:
IdentityService
Defined in:
lib/dnsimple/client/identity.rb

Defined Under Namespace

Modules: StaticHelpers

Instance Method Summary collapse

Instance Method Details

#whoami(options = {}) ⇒ Dnsimple::Response<Dnsimple::Struct::Whoami>

Gets the information about the current authenticated context.

Parameters:

  • options (Hash) (defaults to: {})

Returns:

Raises:

See Also:



14
15
16
17
18
# File 'lib/dnsimple/client/identity.rb', line 14

def whoami(options = {})
  response = client.get(Client.versioned("/whoami"), options)

  Dnsimple::Response.new(response, Struct::Whoami.new(response["data"]))
end