'GoogleCredential is deprecated in Spring Boot
I have looked everywhere about a new implementation of the deprecated GoogleCredential but nothing seems to work in my use case:
We are creating a flutter application as the client and Spring Boot application as the Rest API and we are used to send the access token retrieved from the client (package:google_sign_in) to the API to go throught this lines to get the profile information from google api:
GoogleCredential credential = new GoogleCredential().setAccessToken(accessToken);
Oauth2 oauth2 =
new Oauth2.Builder(new NetHttpTransport(), new JacksonFactory(), credential)
.build();
Userinfo userinfo = oauth2.userinfo().get().execute();
but the issue is that GoogleCredential and JacksonFactory are now depricated. thank you for your advice.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
