google-apps

Find all Google Apps users not using two-factor authentication

旧街凉风 提交于 2019-11-29 11:02:53
We're implementing two-factor authentication for all of our Google Apps users. I've written a script to list the users in a Google Apps domain based on the sample that Google provides ( https://developers.google.com/apps-script/advanced/admin-sdk-directory#list_all_users ) I'd like to filter that list by users who are or aren't using two-factor authentication but I cannot find anywhere in the User API that allows me to do this. Does anyone know who I can find out if a user is using two-factor authentication or not? I found this info in the Reporting API (of the Admin SDK). Here's a snippet I

Received error “Not Authorized to access this resource/api” when trying to use Google Directory API and Service Account Authentication

雨燕双飞 提交于 2019-11-29 10:43:39
I'm really struggling with trying to use Service Account authentication to use the Google Directory API (Admin SDK). Using client based three legged OAuth this works (tested here - https://developers.google.com/admin-sdk/directory/v1/reference/members/insert ) but there's a problem with the permission delegation to the service account I am using. Under the Google Apps administration, I enabled using APIs and added the service account to the list of allowed OAuth clients as instructed. Here is the code: import httplib2 import sys from apiclient.discovery import build from oauth2client.client

Access Google-apps public spreadsheet via Javascript

痞子三分冷 提交于 2019-11-29 10:09:51
问题 Spent a bunch of time looking at this.. It seems that what little info there was about accessing a Google-apps spreadsheet is not very well maintained.. At Google IO this year there was an announcement of enhanced Google-apps script. Including UI elements.. That got me to thinking of creating a widget based on data in Google spreadsheets, no data writing just a simple reading/look up and display calculations.. Then I realized the UI feature was only available for Premier account.. Not a huge

Connecting domain to google app engine without google apps

女生的网名这么多〃 提交于 2019-11-29 09:32:26
问题 Actualy, It's a couple of questions: Is it possible to somehow avoid registering google apps if I just want to connect google app engine applications to non-naked domain (www.example.com for example:) If described above is impossible, than do I have a right to register Google Apps Education Edition. And how can I proof that I'm non-profit if I'm not US resident? If I need to connect a couple of domains to a couple of google app instances must I use a couple of google appss as well? 回答1: Here

Uploading images to a Google Spreadsheet using Apps Script

谁说我不能喝 提交于 2019-11-29 07:52:24
I'm new to scripting. I have copied the code from here Upload image to Google Spreadsheet The original script allowed a user to upload 1 image via the web app form and then the image would append to a row in a Google spreadsheet and into a Google Doc. I have been able to modify the web app form to allow a user to upload 2 images, but I can't figure out how to get the second image into the spreadsheet and doc. var submissionSSKey = 'Google Spreadsheet key'; var docurl = 'Google document URL' var listitems = ['Select a category','Portrait','Landscape','Other','Night shots','Nature','Various']

Can a Google Apps Admin manage users files with Drive SDK?

房东的猫 提交于 2019-11-29 07:08:51
The new Drive SDK is very good for the authenticated user. Is it possible use Drive SDK using Google Apps administrative access to impersonate other domain users? The doclist API can do it but it's not possible manage and copy files (pdf, jpg) with this tool. I'm using Java with this code: credential_origine = new GoogleCredential.Builder().setTransport(HTTP_TRANSPORT) .setJsonFactory(JSON_FACTORY) .setServiceAccountId("[email from console api]") .setServiceAccountScopes(DriveScopes.DRIVE) .setServiceAccountUser("user@domain.com") .setServiceAccountPrivateKeyFromP12File(new File("key.p12"))

Open Google Docs Spreadsheet by name

笑着哭i 提交于 2019-11-29 06:41:05
I have a situation where a script is taking input data and sending it to a spreadsheet. After a while, this spreadsheet becomes too big. Right now we have to manually move the items from the the primary spreadsheet to a new one. The reason is that not everyone is familiar with the code and are willing to change the ID in the code. I would like to know if there is a way to open the spreadsheet by name. If not, is there a better way of achieving what we need (described above) The DocsList service used in one of the answers no longer functions as it has been depreciated. I updated my scripts to

How to skip hidden rows while iterating through Google Spreadsheet w/ Google Apps Script

北城余情 提交于 2019-11-29 06:26:18
I have a Google Spreadsheet with many hidden rows in it, and I want to skip them when iterating through a list of rows in the spreadsheet. It's mainly an efficiency issue, as I'm dealing with over half of my rows being hidden and in no need of being checked. Any help would be appreciated. There's no direct way of doing this in Apps Script, but there is a feature request open to provide a way get the show/hide status of a row, if you want to star it. The issue tracker holds that request since Aug 3, 2010 with a Medium priority and just a "Triaged" status. More than 3 years and no signs of

Google Spreadsheets Regex Case Insensitive (Regexreplace)

孤街浪徒 提交于 2019-11-29 06:02:52
问题 I'm trying to create a case insensitive regex query in Google Spreadsheets with the regexreplace function. Is that possible? I've tried the \i flag and got a #REF error saying the expression was invalid: =regexreplace("Test","t\i","") gives an error when I would hope to get "es" as the final result. Is it possible? Is there a flag for case sensitivity in Google Spreadsheets? Thanks in advance! 回答1: AFAIK, the only way to enable case-insensitive matching is JavaScript API in google docs.

Embedded Google form in email?

和自甴很熟 提交于 2019-11-29 05:02:21
I'm embedded Google form in email by Google apps script but the form doesn't submit correctly from Outlook and from iPhone. It works from Google Mail client only? Is there's away to solve this problem of submission from iphone or outlook? Thanks Amany Mogsdad To use forms embedded in emails, the email client needs to support html forms. Outlook has its own forms, but does not support the html form element ( reference ). I haven't found a reference for iPhone, but it's likely that it also limits the html support. (I use the gmail client on my phone... it supports forms.) If you're using the