Class: OmniAuth::Strategies::Procore

Inherits:
OAuth2
  • Object
show all
Defined in:
lib/omniauth/strategies/procore.rb

Instance Method Summary collapse

Instance Method Details

#callback_urlObject



35
36
37
# File 'lib/omniauth/strategies/procore.rb', line 35

def callback_url
  full_host + script_name + callback_path
end

#raw_infoObject



28
29
30
31
32
33
# File 'lib/omniauth/strategies/procore.rb', line 28

def raw_info
  access_token.client.site = options[:client_options][:api_site]
  version = options[:client_options][:version]
  path = /\Av\d+\.\d+\z/.match?(version) ? "/rest/#{version}" : "/#{version}"
  @raw_info ||= access_token.get("#{path}/me").parsed
end