To obtain a comprehensive list of all published Google Sites within your organization, you can use the free, open-source, Google Apps Manager (GAM). This third-party app also identifies if the sites are accessible outside your organization and outputs the results in a CSV file. For example, use the list to check for accessibility issues or identify internal sites that have games or other functionality.
Important: Google Cloud Support doesn’t support GAM or other third-party solutions. We support the Admin SDK Directory API those tools use. GAM is subject to the Apache 2.0 license, which provides the terms and conditions for your use, reproduction, and distribution of GAM.
Set up GAM
- With GAM version 5.10 and above, before executing GAM for the first time, create a file named noshorturls.txt in the same folder as GAM.
This turns off gam-shortn.appspot.com short URLs. - From the GAM website, download GAM.
- Configure the tool.
Note: During setup, when asked if you’re “ready to authorize GAM to manage Google Workspace user data and settings,” answer N (no) to skip Domain-Wide Delegation. - Enter the following command to confirm that GAM is associated with the right Google Workspace account:
gam info domain
Identify published links
Enter the following GAM command to generate a CSV file containing all published Google Sites and if the site is published outside your organization’s domain.
gam all users show filelist query "mimeType = 'application/vnd.google-apps.site'" id | gam csv - gam user ~Owner show filerevisions ~id | awk -F'ID: |publishedLink: |publishedOutsideDomain: ' '{ gsub(/,.*/, "", $2); gsub(/\s.*/, "", $3); gsub(/\s.*/, "", $4); if ($2 || $3 || $4) { printf "%s,%s,%s\n", $2, $3, $4}}' > publishedlinks.csv