Skip to content
Kim Nilsson edited this page Mar 20, 2021 · 20 revisions

SPOGOU - Set Passwords On a Group Of Users

How to set passwords on many users (a class or an entire school year) provided only an address to a G Suite group, and share the results back to the teacher who asked for it.

Link to copyable SPOGOU.

New addon version SPOGOU addon template

Old script version SPOGOU script template

You can create a copy of this and use that internally. No need to come back here again. Unless you're interested in future updated versions of the script, of course. :-)

Wiki hasn't been updated with addon instructions (yet), as they are inside the addon, and shouldn't need to be explained here.

When you want to create a list of credentials

  1. Click the link with a delegated admin (often superadmin) account, and create a copy of this original.

However, do note that the user running the script doesn't have to be a superadmin! The delegated admin only needs to be able to change passwords, force password changes, and have Groups API read access. So it doesn't even need to be group admin!

It's easy to create a custom admin role for this, with only password reset (with forced change) and read access to groups.

  1. Remove Copy of and - Template from name of spreadsheet. Best is to name the sheet so it refers to whose credentials it will contain when it is finished.

  2. Run Set password on group of users / Prepare sheets. It should ask for authorisation.

  3. Allow access to your superadmin/Delegated Admin account. Else nothing will work.

The script will run, create and prepare a number of sheets.

Nothing happened?

If the script doesn't run after authorisation (Don't look away!), run 'Prepare sheets' again.

No change?

If you see the script running, but you don't observe a change after the script has run (it should add four sheets/tabs at the bottom of the page), reload the entire sheet by clicking the 'refresh' button. The script will have changed the sheet.

  1. Fill in the necessary data in the Indata sheet.

  2. Then run Prepare passwords.

  3. Check the passwords, and if they look fine, run Set passwords.

Passwords will be set, temporarily logged in sheet Log, and the entire sheet will be shared with entered teacher. The spreadsheet will also be cleaned up and unnecessary tabs/sheets will be removed.

  1. When you are done, you need to remove the project from the sheet. Open the Script Editor go to File menu and click Remove Project. If you don't, then the script will be available to the teacher you just shared the list with, and you run a risk of them messing things up.

If you don't want to create a Sheet copy, the scripts are also available here in this repo.

DO NOTE! If you copy the scripts from here, instead of copying the entire Sheets file, you will have to enable the API manually. Here's how you do that. Click the following menus.

Tools / Script Editor Resources Advanced Google Services

Then click the button for

Admin Directory API

Ok and save.

PRIVACY POLICY

You are in full control of all the data. The script is only accessing data you yourself have access to. No data is sent anywhere, except between you and Google. No matter if you create a copy of my Sheet or my scripts, I will never gain access to any of your data. All data reading and writing is done by you on your own account.

paypal

Clone this wiki locally