Method: CloudAlly::Authentication#auth_partner

Defined in:
lib/cloudally/authentication.rb

#auth_partner(options = {}) ⇒ Object Also known as: partner_login

Authorize to the partner portal and return access_token



24
25
26
27
28
29
# File 'lib/cloudally/authentication.rb', line 24

def auth_partner(options = {})
  raise raise ConfigurationError.new "client_id and/or client_secret empty" unless client_id && client_secret
  api_auth('/auth/partner', options)
rescue Faraday::ServerError, Faraday::UnauthorizedError => e
  raise AuthenticationError.new e.to_s
end