Cannot Authenticate Using OAuth 2.0 In Google Calendar (v3) API In JavaScript
I am attempting to create Google Calendar events as per the code given at here. I've narrowed the probem down to an authentication issue in the following call: which does not ret
Solution 1:
I had discovered that popups were blocked in my browser and this prevented the authentication process from completing. Once I enabled popups, the process was able to complete successfully. Doh! The code was complete and OK after all.
Solution 2:
Wierd. Looks like Google doesn't like your credentials.
Have you remembered to call
gapi.client.setApiKey(apiKey)
before tryinggapi.auth.authorize()
?Are
apiKey
andclientId
both defined and in scope? If you're not sure, try stickingalert(apiKey + '\n' + clientId)
orconsole.log(apiKey, clientId)
in the same function.
Post a Comment for "Cannot Authenticate Using OAuth 2.0 In Google Calendar (v3) API In JavaScript"