class Rjawbone::Oauth
Public Class Methods
exchange_code(code)
click to toggle source
# File lib/rjawbone/oauth.rb, line 17 def self.exchange_code(code) check_oauth_config params = { :code => code, :grant_type => "authorization_code", :client_id => Rjawbone.configuration.client_id, :client_secret => Rjawbone.configuration.client_secret } JSON.parse RestClient.post(Rjawbone::TOKEN_URL, params) end