Open sirramin opened 8 years ago
What did Google tell you?
@EddyVerbruggen
window.plugins.googleplus.login(
{
'scopes': '... ', // optional, space-separated list of scopes, If not included or empty, defaults to `profile` and `email`.
'webClientId': 'client id of the web app/server side', // optional clientId of your Web application from Credentials settings of your project - On Android, this MUST be included to get an idToken. On iOS, it is not required.
'offline': true, // optional, but requires the webClientId - if set to true the plugin will also return a serverAuthCode, which can be used to grant offline access to a non-Google server
},
function (obj) {
alert(JSON.stringify(obj)); // do something useful instead of alerting
},
function (msg) {
alert('error: ' + msg); // here : msg = 8
}
);
Nothing. When I debug my code just the error function called and msg parameter has value "8" and I can't understand what's that mean
Google finds a lot of results, fi indicating your SHA isn't correct. So you're probably testing on Android.
Yes! it is due to incorrect SHA.. Ive fixed it by replacing correct SHA.
@EddyVerbruggen Thanks so much for your additions to the cordova plugin community. You are amazing.
I apologize if this has been answered already. Is there a straightforward answer to correcting the SHA so that I can test on my Android device? I have created separate OAuth Client ID's, one with my app's release keystore SHA1 signature and with the debug.keystore signature. These ID's are both part of the same project. I have tried removing and re-adding your plugin with the Android Client ID of both with no success. I am attempting to login and getting the "8" error msg always.
My scopes are the drive and games api's.
If this question has be answered, I would greatly appreciate a link to an answer with my particular problem. I have a Cordova app that is built for both Android and iOS.
Thank you!
I got this error number, what's that mean?