Search in sources :

Example 1 with GoogleAPI

use of org.mamute.auth.GoogleAPI in project mamute by caelum.

the class GoogleAuthController method signUpViaGoogle.

@Get("/sign-up/google/")
public void signUpViaGoogle(String state, String code) {
    Token token = service.getAccessToken(null, new Verifier(code));
    SocialAPI googleAPI = new GoogleAPI(token, service);
    loginManager.merge(MethodType.GOOGLE, googleAPI);
    redirectToRightUrl(state);
}
Also used : GoogleAPI(org.mamute.auth.GoogleAPI) Token(org.scribe.model.Token) Verifier(org.scribe.model.Verifier) SocialAPI(org.mamute.auth.SocialAPI) Get(br.com.caelum.vraptor.Get)

Aggregations

Get (br.com.caelum.vraptor.Get)1 GoogleAPI (org.mamute.auth.GoogleAPI)1 SocialAPI (org.mamute.auth.SocialAPI)1 Token (org.scribe.model.Token)1 Verifier (org.scribe.model.Verifier)1