Class: OmniAuth::Strategies::Litmus

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

Constant Summary collapse

OAUTH_HOST =
ENV["LITMUS_OAUTH_HOST"] || "https://litmus.com"
API_HOST =
ENV["LITMUS_API_HOST"] || "https://api.litmus.com"

Instance Method Summary collapse

Instance Method Details

#callback_urlObject



30
31
32
# File 'lib/omniauth/strategies/litmus.rb', line 30

def callback_url
  full_host + callback_path
end

#raw_infoObject



23
24
25
26
27
28
# File 'lib/omniauth/strategies/litmus.rb', line 23

def raw_info
  access_token.options[:mode] = :query
  @raw_info ||= access_token.
                  get("#{API_HOST}/v2/users/current").
                  parsed["user"]
end