google-oauth

Incremental combined authorization with Google SignIn for Server-Side Apps

独自空忆成欢 提交于 2020-01-12 06:14:29
问题 When login with Server-Side flow, or ask authorization for additional scopes, with auth2.grantOfflineAccess , the result access/refresh token is not getting combined with previous authorized scopes, overriding the previous ones. Even passing the param to js calls, e.g. auth2.grantOfflineAccess({'include_granted_scopes' : 'true', ...}) , the param include_granted_scopes=true is NOT added to the generated URL. When I manually append the param &include_granted_scopes=true to the generated url on

Google OAuth error -1001

亡梦爱人 提交于 2020-01-11 12:25:30
问题 In my application i have try to implement the google account access, and when i initialise its working till in the login session. after which it throws the following error in the screen shot Here my code Initialisation and method implementation static NSString *const kKeychainItemName =nil; NSString *kMyClientID = @"465568347336.apps.googleusercontent.com"; NSString *kMyClientSecret = @"rKVsWXTlo3M8zqNfofkX0Xrl"; NSString *scope = @"https://www.googleapis.com/auth/userinfo.profile";

OAuth2 authorization from Java/Scala using google gdata client API

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-11 11:30:14
问题 How would you perform the same flow as the Google .Net sample at subsection "Performing OAuth 2.0", using an equivalent Java api? That .Net sample I am trying to mimic using Java api seems fit for sending an api request to create an authorization url, then assumes I would use that url in a browser to obtain an access code... thus allowing server-side code to use google spreadsheets api thereafter, for that one google account. The closet Google Java api class I spotted is OAuthHelper, but it

Deleting Gmail Emails via Google API using Powershell v2.0

吃可爱长大的小学妹 提交于 2020-01-11 10:48:48
问题 $user = "example@gmail.com" $pass= "examplepassword" $secpasswd = ConvertTo-SecureString $user -AsPlainText -Force $cred = New-Object System.Management.Automation.PSCredential ($pass, $secpasswd) Invoke-RestMethod 'https://www.googleapis.com/gmail/v1/users/me/messages/0' -Method Delete -Credentials $cred So, my problem here is twofold. I originally tried using Invoke-WebRequest to delete gmail emails via the Google API with a http delete request. However, this did not work because Powershell

Unable to refresh OAuth2 token in PHP, invalid grant

情到浓时终转凉″ 提交于 2020-01-11 09:55:14
问题 I need to make a PHP script that creates a sigle event on Google Calendar. I had no problems setting up client id, client secret, dev key and creating a new event. My only problem is with OAuth2, in particular I need to make a permanent connection and I do not want to do the authentication everytime I run the script. Actually, with this script I'm able to get a token and a refresh token, but every hour my token expires and I don't know how to refresh it. How can I edit this code to do that?

Google OAuth 2.0 Service Account - Calendar API (PHP Client)

若如初见. 提交于 2020-01-11 07:11:35
问题 I have a Google Apps account. I am trying to manipulate a users Calendar within this account. I have created the Project, added the Calendar API service and created a Service Account OAuth 2.0 Client ID through the API console. I have added that generated Email address to the Calendar through the Calendar settings to share the calendar. I have followed the steps suggested to Manage the API access. The client name is the same domain that the Google Apps account is on, and the scope is "https:/

Google API OAuth for Drive API is not working. Getting Error: origin_mismatch

久未见 提交于 2020-01-11 03:11:08
问题 I am trying to run the quick start code of Real Time API of Google Drive. I believe I did everything right. But I am getting Error: origin_mismatch Request Details openid_connect_request=true cookie_policy_enforce=false scope=https://www.googleapis.com/auth/drive.install https://www.googleapis.com/auth/drive.file https://www.googleapis.com/auth/plus.me response_type=token access_type=online redirect_uri=postmessage proxy=oauth2relay601571239 origin=http://127.0.0.1 state=811328575|0.818765953

Google Service Account Authentication with Json file

与世无争的帅哥 提交于 2020-01-10 19:15:14
问题 I have been following the Oauth2 Service account documentation on Googles website. I have also been picking apart Googles .net client libray trying to get this to work. I have reached the Computing the signature stage. The privacy key from Google looks like this -----BEGIN PRIVATE KEY-----\nMIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQDcmuyQC8rwWdPQ\nmIdksgzSJbVWTU5MeUxy+HAap3yut9wR/L6KGMJ4FBYcsPmXN5gQAhErybavGoZG\nfS1X1/PCpPVpTCA4749K8gbvuZg1JEIAqMtmHiBBrJj5l8eiekQc8pd7Pq35H4wi

invalid_client in google oauth2

…衆ロ難τιáo~ 提交于 2020-01-08 16:05:52
问题 I try to make a web page for youtube video upload, therefore I try to get the client id from google api console, and in the api console it shows something like this: Client ID: 533832195920.apps.googleusercontent.com Redirect URIs: http://bobyouku.ap01.aws.af.cm/testyoutube.php https://developers.google.com/oauthplayground However when I try to test my account using the following URL: https://accounts.google.com/o/oauth2/auth?client_id=533832195920.apps.googleusercontent.com&redirect_uri=http

invalid_client in google oauth2

爱⌒轻易说出口 提交于 2020-01-08 16:05:49
问题 I try to make a web page for youtube video upload, therefore I try to get the client id from google api console, and in the api console it shows something like this: Client ID: 533832195920.apps.googleusercontent.com Redirect URIs: http://bobyouku.ap01.aws.af.cm/testyoutube.php https://developers.google.com/oauthplayground However when I try to test my account using the following URL: https://accounts.google.com/o/oauth2/auth?client_id=533832195920.apps.googleusercontent.com&redirect_uri=http