diff --git a/social/backends/goclioeu.py b/social/backends/goclioeu.py new file mode 100644 index 000000000..f5b36c46b --- /dev/null +++ b/social/backends/goclioeu.py @@ -0,0 +1,14 @@ +from social.backends.goclio import GoClioOAuth2 + + +class GoClioEuOAuth2(GoClioOAuth2): + name = 'goclioeu' + AUTHORIZATION_URL = 'https://app.goclio.eu/oauth/authorize/' + ACCESS_TOKEN_URL = 'https://app.goclio.eu/oauth/token/' + + def user_data(self, access_token, *args, **kwargs): + """Loads user data from service""" + return self.get_json( + 'https://app.goclio.eu/api/v2/users/who_am_i', + params={'access_token': access_token} + )