android-google-signin-unity
android-google-signin-unity copied to clipboard
How can I get the Authorization code?
Hello!
I am able to sign in and get the ID token. The thing is I need the access token and refresh token to connect to another api, but therefor i need the authorization code for the request. How can I get that one with your script?
Thanks, Julia
Hi, I read the docs and found this which also requires server-side code to get an access token (and refresh token). Is that what you need?
If yes, you would also have to provide a serverClientId, as mentioned here
I can try to add this if it's what you need.
yes, this is what i need. I'm trying to get Google Poly on Android running and for private assets I need Oauth to have access to them and the Poly API just implements Oauth for Desktop, but not for Android. I am playing around by myself to get this working.
I have pushed a new branch but I haven't tested it.
You can try it, you will have to call the method SignInWithServerClientId and pass the serverClientId, then in you success callback you should get an object that contains public string ServerAuthCode.
Let me know if that works.