class Gosns::Googleplus
Attributes
key[RW]
redirect_uri[RW]
secret[RW]
Public Class Methods
oauth_client()
click to toggle source
# File lib/provider/googleplus.rb, line 14 def oauth_client option = { site: 'https://accounts.google.com', authorize_url: "/o/oauth2/auth", token_url: "https://www.googleapis.com/oauth2/v3/token" } OAuth2::Client.new(key, secret, option) end
token(code)
click to toggle source
# File lib/provider/googleplus.rb, line 23 def token(code) oauth_client.auth_code.get_token(code, redirect_uri: redirect_uri) end
Public Instance Methods
followers()
click to toggle source
# File lib/provider/googleplus.rb, line 27 def followers Helper::parse_int Helper::at_css("https://plus.google.com/+#{account}", ".BOfSxb") end