Class: OmniAuth::Strategies::Moves

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

Constant Summary collapse

DEFAULT_SCOPE =
'activity location'

Instance Method Summary collapse

Instance Method Details

#auth_hashObject



23
24
25
# File 'lib/omniauth/strategies/moves.rb', line 23

def auth_hash
  OmniAuth::Utils.deep_merge(super, client_params.merge({:grant_type => 'authorization_code'}))
end

#callback_urlObject



31
32
33
# File 'lib/omniauth/strategies/moves.rb', line 31

def callback_url
  full_host + script_name + callback_path
end

#raw_infoObject



27
28
29
# File 'lib/omniauth/strategies/moves.rb', line 27

def raw_info
  @raw_info ||= access_token.get('https://api.moves-app.com/api/v1/user/profile').parsed
end

#request_phaseObject



18
19
20
21
# File 'lib/omniauth/strategies/moves.rb', line 18

def request_phase
  options[:authorize_params] = client_params.merge(options[:authorize_params])
  super
end