Class: OmniAuth::Strategies::GitHub
- Defined in:
- lib/omniauth/strategies/github.rb
Overview
OAuth 2.0 based authentication with GitHub. In order to sign up for an application, you need to [register an application](github.com/account/applications/new) and provide the proper credentials to this middleware.
Instance Attribute Summary
Attributes inherited from OAuth2
#client_id, #client_options, #client_secret, #options
Instance Method Summary collapse
-
#initialize(app, client_id = nil, client_secret = nil, options = {}, &block) ⇒ GitHub
constructor
A new instance of GitHub.
Methods inherited from OAuth2
Constructor Details
#initialize(app, client_id = nil, client_secret = nil, options = {}, &block) ⇒ GitHub
Returns a new instance of GitHub.
13 14 15 16 17 18 19 20 21 |
# File 'lib/omniauth/strategies/github.rb', line 13 def initialize(app, client_id = nil, client_secret = nil, = {}, &block) = { :site => 'https://github.com/', :authorize_path => '/login/oauth/authorize', :access_token_path => '/login/oauth/access_token' } super(app, :github, client_id, client_secret, , , &block) end |