Google OAuth2.0 - velruse.providers.google_oauth2

Google Developer Links:

Settings

consumer_key
Google application consumer key.
consumer_secret
Google application consumer secret.
scope
Authorization scope.

POST Parameters

Complete Example:

<form action="/velruse/google/login" method="post">
    <input type="submit" value="Login with Google" />
</form>

Pyramid API

class GoogleAuthenticationComplete(profile=None, credentials=None, provider_name=None, provider_type=None)[source]

Bases: velruse.AuthenticationComplete

Google OAuth 2.0 auth complete

includeme(config)[source]

Activate the google_oauth2 Pyramid plugin via config.include('velruse.providers.google_oauth2'). After included, two new methods will be available to configure new providers.

config.add_google_oauth2_login()
See add_google_login() for the supported options.

config.add_google_oauth2_login_from_settings()

add_google_login(config, consumer_key=None, consumer_secret=None, scope=None, login_path='/login/google', callback_path='/login/google/callback', name='google')[source]

Add a Google login provider to the application supporting the new OAuth2 protocol.