class OmniAuth::Strategies::Weebly
Public Instance Methods
build_access_token()
click to toggle source
# File lib/omniauth/strategies/weebly.rb, line 23 def build_access_token token_params = { :redirect_uri => callback_url.split('?').first, :client_id => client.id, :client_secret => client.secret } verifier = request.params['code'] client.auth_code.get_token(verifier, token_params) end
raw_info()
click to toggle source
# File lib/omniauth/strategies/weebly.rb, line 43 def raw_info access_token.options[:parse] = :json # This way is not working right now, do it the longer way # for the time being # #@raw_info ||= access_token.get('/ap/user/profile').parsed url = "/v1/user" params = {:headers => {'X-Weebly-Access-Token' => access_token.token}} @raw_info ||= access_token.client.request(:get, url, params).parsed end