google-api,google-drive-sdk,google-oauth,service-accounts , Google Service account user interfece

Google Service account user interfece


Tag: google-api,google-drive-sdk,google-oauth,service-accounts

How can I login to a Google Service account with the normal web user interface, for example to google drive ?

Now I can only login using API using script.


You cant. A service account is a sudo user type thing. Yes it has a Google drive account, Google calendar ... but you cant log in to the web interface for Service accounts.

Option / work around / Tip:

There is a slight workaround. You could have the service account give your Google account access to a directory on its Google drive. Then when you login to Google Drive web you will be able to see the files. Tip: If you want to be able to interact with the files the service account will also have to grant you access to each of the files in the directory.

You can use files.patch and permissions to achieve this.


Google Scripts + Google API PHP

I am trying to call one of my Google Scripts from my google-api-php-client and I can't find how to do this. I deployed my app as a web app, and I got the web app url which I can call with curl, but I need to call it as my...

finished with non-zero exit value 2 when I use google login api

I want to access the google account to login my app,and I get: Error:Execution failed for task ':app:dexDebug'. > org.gradle.process.internal.ExecException: Process 'command '/Library/Java/JavaVirtualMachines/jdk1.8.0_40.jdk/Contents/Home/bin/java'' finished with non-zero exit value 2 My build.grade: apply plugin: '' android { compileSdkVersion 22 buildToolsVersion '22.0.1' defaultConfig { applicationId "" minSdkVersion 15 targetSdkVersion 21...

Limited number of rows returned from Google spreadsheet and the Sheets Api

I have a spreadsheet on Google Drive with 571 rows that I read from an other application. I call it using the Google.GData.Spreadsheets 2.2.0 lib and the following piece of simplified code. static void Main(string[] args) { var certificate = new X509Certificate2("Key.p12", "blahblah", X509KeyStorageFlags.Exportable); const string user = "[email protected]"; var...

How to by pass authentication in google analytics script?

I would like to display a Google Analytics report in my web application. So far I have successfully Authenticated a user through OAuth with server side and I have successfully stored AccessToken and UserProfileId in my database Table. Now I want to display Chart like Below: Here is the script...

How can I make a copy of a file in Google Drive via Python?

I wrote a short function in Google Apps script that can make a copy of a specific file that is stored on Google Drive. The purpose of it is that this file is a template and every time I want to create a new document for work I make a...

Is it possible to use service account with google cloud print [duplicate]

This question already has an answer here: Share printer with Google API Service Account 1 answer I have an application that uses google cloud print. The printers are registered on a company google account. I have to change the application to use oAuth now and since the application runs...

Google Logging API - What service name to use when writing entries from non-Google application?

I am trying to use Google Cloud Logging API to write log entries from a web application I'm developing (happens to be .net). To do this, I must use the logging.projects.logs.entries.write request. This request dictates that I provide a serviceName argument: { "entries": [ { "textPayload": "test", "metadata": { "serviceName":...

401 Unauthorized - Google Drive API,.net,,google-drive-sdk
I'm working with the Google APIs for the first time and I'm having problems trying to download files with the File object "downloadUrl" property. I'm currently using the "Service Account" option with the associated service account email and P12 certificate. However, the URL returned "" returns a 401 - Unauthorized...

What is the difference between Android API and Google API?

I have gone through some of the links that difference between the Google API and android API.I have not got clear explanation.Anyone Can you help me please?

Insert file using Google Drive API?

Based on Google Drive API reference guiding how to insert file Files.insert // File's metadata. File body = new File(); body.setTitle(title); body.setDescription(description); body.setMimeType(mimeType); // File's content. fileContent = new; FileContent mediaContent = new FileContent(mimeType, fileContent); try { File file = service.files().insert(body, mediaContent).execute(); // Uncomment the following line to...

Gmail API: Insufficient Permission

THE SITUATION: I am testing the Gmail API for my app. I have tested some requests and they are working fine. For example get messages, get user history, get draft list etc.. Basically all the read only requests are working fine. I have instead some issues related with permission with...

Google Translate API text-to-speech: http requests forbidden

I am making a language learning web app that when you hover over the word, it pronounces it for you. I'd like to access the native speaker translations from Google Translate API. I've found this resource which gives as the base URL and tl for target language and q...

Google Developer API V3 for video upload in YouTube

I have been using google's reputed API V2 for uploading the videos on YouTube from my web application as there has been up gradation in API to V3 , I am unable to upload the same through the same code. I have tried with the new application for uploading the...

Unable to implement Google API 'Search using a specific app'

I am trying to implement the 'Search using a specific app' functionality as per the android documentation. But I am unable to get it working. This is my query 'Ok google, search for xyz on helloapp' Following is my implementation. I have added meta data which is not required, but...

Google Drive API 500 null errors when copying

I'm getting this error message (100% of the time) when copying a shared file, using the latest version of php library. And I'm getting the same response via the API explorer: Google_Exception: Error calling POST (500) { "error": { "code": 500, "message": null } } This issue seem...

Making an iOS authorised Google API call

I have integrated Google Sign-in into my iOS app and retrieved the access tokens after signing in. I am now wanting to make authorised API calls to Google, but am unsure how to do this to include the token. Can someone please share some code that I can use to...

Google Drive API VB.NET Parent Folder of a Folder,google-drive-sdk,folder,parent
I am trying to work with Google Drive API with I have seen a lot of post but I am not able to understand how to choose the right folder to add a file. I have a lot of "Backup" folder but, I assume now, I want to add...

How to create a script to query Google Browserlocation

I'm trying to figure out a way to get geolocation data from Google's Browser location API. I found JSON, CURL and Google's geolocation, and have it working as far as list of access points in range, but my limited cli-fu won't let me parse this into something I can send...

Advanced Drive Services in Addons

I have a Google Script that uses the Advanced Drive API service and am now looking to convert this script into an Add-on. However the Drive API needs to be enabled manually by the user before using the service inside the Apps Script. Is it possible to use the advanced...

Are there google apis to update a google sheet

I want to listen to calendar events and update cells in the google sheet. I have found apis for calendar but are there any apis available to update cells in google sheet ? Thanks...

Failed sending mail through google api with javascript

I'm trying to send an email through Google API with JavaScript. My issue is that when I try to send a simple mail with no attachments, I get the following error: 'raw' RFC822 payload message string or uploading message via /upload/* URL required` My code function sendMessage() { gapi.client.load('gmail', 'v1',...

How to access gmail API?

I generate my JWT, if my token is correct why dont work ? in Google Developers Console i enabled gmail plus youtube and other API, in credentials generate and download json { "private_key_id": "22dcf", "private_key": "-----BEGIN PRIVATE KEY-----(remove)-----END PRIVATE KEY-----\n", "client_email": "[email protected]", "client_id": "", "type": "service_account" } first generate token...

Can one track the usage of a shared resource from google drive

Does anyone here know if you on Google Drive somehow can track if a public shared link to a file have been used? That is, the resource have been downloaded, viewed or otherwise "touched"?...

Can I associate a user's account with an action to the drive API?

We're looking to make a little webapp to manage our week-long nerf war (humans vs zombies to be precise), and we're thinking about how easy it would be to have Google Sheets be our only backend, and our frontend be entirely javascript/html/css. Let's say there's two actions that can be...

How to use nextPageToken in Google Apps Reseller API?

I am writing a simple Java application that fetches all customer subscriptions from Google Apps Reseller using the Reseller API. However I am stuck at paging through the results as the max size is 100 per page and I cannot figure out the next page token. Here is the code...

Providing login_hint option for Google Oauth2 redirect

I'm passing in login_hint=1 option as part of Oauth2 request query string but this doesn't appear when I receive a callback from Google Oauth2 after accepting it. I'm only getting: google/oauth2callback?code=4/vadsdaalijfqwo8fdjqojcxadassddsa# I was expecting 1 (which is user id) to come back as part of callback. How do I make...

Freebase Search API - Get All Results

Is it possible now to get all results from Freebase Search API? Today I was trying 2 approaches in Java: 1)" Using "cursor"(integer) and "limit" options. 2) Try to simulate 'Query Editor' ( Using "cursor" from the previous results set (String). But in both of these approaches I...

Google Drive API (GTL) - Create multiple folder paths in order?

I'm using the Google APIs Client Library for Objective-C (GTL) to access the Google Drive API. According to it's Introduction to the Google APIs Client Library for Objective-C, Query execution by the service is inherently asynchronous. Which means when you try to create a path like: root/a/b/c, before you can...

Google Cloud Datastore PropertyFilter Error

I'm using the google apis php sdk and trying to access some data from my google cloud datastore. I'm authenticating no problem at this point, but am getting an error during my query. I pretty much look through the code in the sdk to implement it, since documentation is null,...

Advanced gmail search for received emails only

I'm using the Google gmail API to get emails from peoples gmail account. I filter for emails containing the word "CompanyName" which have a pdf as an attachment. using the following search query: CompanyName filename:pdf. I now want to further specify this by only getting emails that were received, instead...

Annotation chart google function after rangechange

I'm using the annotation chart and the map from google api, I would like to know if there's anyway to trigger a function after the range change when the user's clic releases. I just find this, 'rangechange', feed_with_chartMap); in the documentation but the function is not only called when...

access drive with access token

struggling to understand the oauth2 token and refresh token processes ive got this code $url = ''; $data = array('client_id' => 'clientid', 'client_secret' => 'secret','refresh_token' => 'token','grant_type' => 'refresh_token'); $options = array( 'http' => array( 'header' => "Content-type: application/x-www-form-urlencoded", 'method' => 'POST', 'approval_prompt'=>'force', 'access_type'=>'offline', 'content' => http_build_query($data), ), ); $context...

Google Identity Toolkit returns INVALID_CREDENTIALS

I'm currently trying to implement a forgot password feature using the Google Identity Toolkit. The PHP backend is trying to get the oob code because client (iOS) does not have sufficient privileges. Whenever I run the script I get an error of INVALID_CREDENTIALS, more specifically: oob Code: string(249) "{ "error":...

I want to upload video on youtube using client side login. without open web page permission

When I upload video to YouTube using client side login. The first time redirect to UI for permissions. I want upload without redirect to web page. I need to execute this code on server. Here is my code. private async Task<string> Run(string title, string description, string filepath) { var videoID...

Access spreadsheet via Google API invalid_grant

I have created a google form, and keeping the form result in an excell sheet named yht_istekler. I am using following code snippet. taken from Create Spreadsheet using Google Spreadsheet API in Google drive in Java Though I am getting following error, what am I doing wrong? List<TrenSeferScheduleEvent> trenSeferScheduleEventList =...

unable to add callback: cannot be converted to ConnectionCallbacks

I am trying to add call back to my googleApiClient with addConnectionCallbacks mPlusClient = new GoogleApiClient.Builder(this).addConnectionCallbacks(this).addOnConnectionFailedListener(this).addApi(Plus.API).addScope(Plus.SCOPE_PLUS_LOGIN).build(); but i am getting this error: Error:(85, 81) error: incompatible types: PlusBaseActivity cannot be converted to ConnectionCallbacks I am gotten this code from an online tutorial but it doesnt seems to work, please help....

Google Analytics Embed API: Display specific account data, not authenticated users

I have this example - Embed API Third Party Visualizations - working locally and on a test server, but I'm unsure of what I need to do to ONLY display our organization's Google Analytics data instead of the user's personal GA account. I created the project and clientID within our...

Gmail API: How to get access token?

I am testing the Gmail API. So far I have done the following: I have created the project in the Google Developers Console I have enabled the Gmail API. I have created a new Client ID and the client secret. In my PHP script I have installed the PHP Client...

Value cannot be null. Parameter name: baseUri

I am using Google BigQuery API with Service Account Authorization in C# console application. When i am trying to load CSV job, it throws "Value cannot be null. Parameter name: baseUri" Exception. It specific on only single table, when i am changing the table name it all gets work. Here...

Getting user credentials using Google+ API

I am trying to include Google sign in in my android application using Google+ Api. I am able to take account details from the user but once signed in I am getting null when requesting for username using call: Plus.PeopleApi.getCurrentPerson(mGoogleApiClient).getDisplayName() And Logcat shows: BasicNetwork.performRequest: Unexpected response code 403 for

Directory sandboxed access for Google Drive / Dropbox API / RemoteStorage apps?

Is there a way to get sandboxed, user-selected directory access on any major file service without first getting read level access to their entire filesystem? There's a lot of talk about "unhosted" static webapps that allow users to access their data from a 3rd party file service (Google Drive, Dropbox,...

Google Calendar: How to check guest is not busy and available to book through google calendar

I am exploring to write google calendar api integration through google scripts or apis. Is there a way I can check a guest is available before I book an event ?...

Google Weather API

I want to make an app using Google weather API. But I don't have any knowledge about it. How do I use API? Could you explain step by step how I start project?

Gmail API: example of a request to the API

I am trying access the Gmail API with my application. I should have done properly all the setup and I am testing a request to the API, in the specific the request to get the messages as read only. My code: public function gmail_get_messages() { $client = new Google_Client(); $client->setApplicationName("Gmail...

Google Drive API: I have to fetch only files in that folder without trashed files

I am trying to get a list of files in a folder on Google drive using the Google drive API. When I make my request I am getting a list of child elements in that folder including previous deleted files. How do I get only the files that are in...

How to save my data in a cloud?

I don't know if this is possible, but I would like to save some data of my website, like images and documents in a cloud like dropbox or google drive and I want that these data are available and visible to someone looking my site. is it possible? (My intention...

Hide referrer header in API request

I need to make requests to Google Translate Text-To-Speech API. I have an enabled key but keep getting blocked by No Access-Control-Allow-Origin. I've posted more about it here: Google Translate API - No Access Control Origin with Text to Speech The following sources, and Request to Google Text-To-Speech API...

Why this google font is not working?

Have this line on my label and is working properly on a Debian server under Apache, but when I uploaded it to my production server (Debian with Apache too) i cannot get the Open Sans Condensed font. <link href=',300,300italic' rel='stylesheet' type='text/css'> Here's the entire : <head> <meta charset="UTF-8" /> <meta...