Module: Rack::Rpx::Methods
- Defined in:
- lib/rack-rpx.rb
Overview
Helper methods intended to be included in your Rails controller or in your Sinatra helpers block
Instance Method Summary collapse
-
#get_credentials(token) ⇒ Object
This is the method you want to call.
-
#login_widget_url(app_name = nil) ⇒ Object
This method will return to sign in with the widget.
Instance Method Details
#get_credentials(token) ⇒ Object
This is the method you want to call.
After you’re authorized and redirected back to your #redirect_to path, you should be able to call get_credentials to get and hold onto the access token for the user you’ve been authorized as.
32 33 34 |
# File 'lib/rack-rpx.rb', line 32 def get_credentials(token) Rack::Rpx.get_credentials(token) end |
#login_widget_url(app_name = nil) ⇒ Object
This method will return to sign in with the widget.
37 38 39 |
# File 'lib/rack-rpx.rb', line 37 def (app_name=nil) "https://#{app_name}.rpxnow.com/openid/v2/signin?token_url=#{callback_url}" end |