Note: A Desktop is a system that doesn't have google's SDK support and is able to launch a web view, such as Java GUI, .NET GUI and so on.
You will follow Google's Installed Applications flow, get the auth code and send it to http://your-backend/token/new/social/by-auth-code/google/desktop .
- Create a Google Client ID. Pick "Other" on "Application type" selection.
- See googleCodeLoginBtn.addActionListener(). You will construct the facebook auth url, launch it with a web view inside your client application.
- See WebEngineChangeListener.changed(). You will monitor the browser's URL until you get the auth code, and then send the code to srb4j's back end.
- The back end's code is getEmailFromCode. You don't need to change it, but you will set "googleClientId" and "googleClientSecret" on app.properties.