A growing collection tools for managing a G Suite organization.
- Install the requirements into a Python 3.8+ virtualenv. (
pip install -e .
) - Set up an OAuth application for Google APIs.
Follow the instructions on this page
for "installed software" authentication and once you have a
client_secret.json
file, plop it in the working directory here.
python -m gst.get_group_info --domain=mydomain.com --write-json=groups.json
To convert groups.json
into a mapping of group-email -> member-emails, using Jq:
jq '.[]|[{"key":.email,"value":[._members[].email]}]|from_entries' groups.json
To convert groups.json
into human-readable Markdown:
python -m gst.format_group_info --json=groups.json --write-markdown=-
python -m gst.get_user_info --domain=mydomain.com --write-json=users.json
To list users with their email aliases:
python -m gst.list_user_emails --json=groups.json -w-