mirror of
https://github.com/GAM-team/GAM.git
synced 2026-06-07 07:41:38 +00:00
Compare commits
139 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b9a489251b | ||
|
|
3b9a9ba224 | ||
|
|
0d63a85a45 | ||
|
|
a8ea30e19e | ||
|
|
660e9deb70 | ||
|
|
ad5ba656ee | ||
|
|
991b1aa33b | ||
|
|
51fafdb735 | ||
|
|
52f1e998fd | ||
|
|
0f144b24d0 | ||
|
|
52d0b0a84b | ||
|
|
28224045b2 | ||
|
|
3fbb261821 | ||
|
|
0b4a4a270e | ||
|
|
177f5f0792 | ||
|
|
57e0cc80af | ||
|
|
1e67310f3d | ||
|
|
e661641544 | ||
|
|
81aa9c6e16 | ||
|
|
8c3b49a967 | ||
|
|
13c6893b67 | ||
|
|
6702e4db30 | ||
|
|
2ed23c8f55 | ||
|
|
24a58c8edc | ||
|
|
0112264291 | ||
|
|
fa5af0ed1f | ||
|
|
15e3f50a3c | ||
|
|
24b7c65754 | ||
|
|
2429e99e18 | ||
|
|
ff41390c85 | ||
|
|
d8d68e8eb0 | ||
|
|
2196e70e7b | ||
|
|
4f79a29155 | ||
|
|
0290f0d0ce | ||
|
|
b7c96a8172 | ||
|
|
fed1662eb4 | ||
|
|
077747be99 | ||
|
|
9eee475b4a | ||
|
|
2636dd9827 | ||
|
|
e18a70e55b | ||
|
|
e11123fccd | ||
|
|
536ea84321 | ||
|
|
4d953ac09b | ||
|
|
d9ce0acd83 | ||
|
|
f735e5e268 | ||
|
|
97358d15ef | ||
|
|
ea0886229e | ||
|
|
4e5462c704 | ||
|
|
ed2291bedf | ||
|
|
44ff2eba62 | ||
|
|
77fb2d0693 | ||
|
|
cea5a33856 | ||
|
|
3a7f84e49d | ||
|
|
5136c0a268 | ||
|
|
8e877a938e | ||
|
|
ed695b234f | ||
|
|
83179be184 | ||
|
|
8e105091d4 | ||
|
|
428be889a2 | ||
|
|
758519b1b3 | ||
|
|
47e2ba95eb | ||
|
|
881cbbea61 | ||
|
|
3ebfb98a98 | ||
|
|
0dbd95832f | ||
|
|
78acf64f7b | ||
|
|
4c7f03da7d | ||
|
|
3ac28ef231 | ||
|
|
7100abab12 | ||
|
|
1d531d13e4 | ||
|
|
df5af20b49 | ||
|
|
cfe6376c28 | ||
|
|
e271e18feb | ||
|
|
33d579985a | ||
|
|
887628ef87 | ||
|
|
4a969e716e | ||
|
|
363c041bbb | ||
|
|
2e151eb81b | ||
|
|
b7fe258aaf | ||
|
|
7a10f6627c | ||
|
|
613cae987f | ||
|
|
cd34c3d1e2 | ||
|
|
899200399c | ||
|
|
46c3f88280 | ||
|
|
3ddef79cbf | ||
|
|
546f31c123 | ||
|
|
443fca3f00 | ||
|
|
720d667b61 | ||
|
|
bb54fd113f | ||
|
|
aa05956d44 | ||
|
|
4b9694b760 | ||
|
|
804fb50ce4 | ||
|
|
22e0c1c355 | ||
|
|
4f6184503c | ||
|
|
fcdc333118 | ||
|
|
a09d849193 | ||
|
|
b53e6b9716 | ||
|
|
5796592288 | ||
|
|
9e32054d85 | ||
|
|
d588f7af43 | ||
|
|
01ce6319e8 | ||
|
|
49b6e03919 | ||
|
|
ac14037eb3 | ||
|
|
6135e5c2a2 | ||
|
|
540104161d | ||
|
|
3a235594b0 | ||
|
|
47eca41f2f | ||
|
|
eedb08513f | ||
|
|
8b4e38154e | ||
|
|
14e9b14bbf | ||
|
|
280805a917 | ||
|
|
5ce4ccdbeb | ||
|
|
a8f9fb7b81 | ||
|
|
aab8db0b84 | ||
|
|
5e6566618f | ||
|
|
415556603a | ||
|
|
f4566f4911 | ||
|
|
161a994dbf | ||
|
|
14f50e2433 | ||
|
|
a96db8cc88 | ||
|
|
ad45e31c27 | ||
|
|
9042bbaa30 | ||
|
|
1912765a83 | ||
|
|
0109e9b701 | ||
|
|
8973edf455 | ||
|
|
feb0a05d69 | ||
|
|
f7b5cdfb2b | ||
|
|
5b62fcb482 | ||
|
|
43dc914049 | ||
|
|
622d28af19 | ||
|
|
a0f0866551 | ||
|
|
d68d6711f5 | ||
|
|
d13001db1d | ||
|
|
0e393e0224 | ||
|
|
c1d13fa0f2 | ||
|
|
3445f648c0 | ||
|
|
677f683377 | ||
|
|
85e90ec56c | ||
|
|
53c9544456 | ||
|
|
be8ae5957b |
29
.github/workflows/build.yml
vendored
29
.github/workflows/build.yml
vendored
@@ -91,7 +91,7 @@ jobs:
|
||||
freethreaded: false
|
||||
goal: build
|
||||
name: Build Arm MacOS 26
|
||||
- os: windows-2025
|
||||
- os: windows-2025-vs2026
|
||||
jid: 12
|
||||
freethreaded: false
|
||||
goal: build
|
||||
@@ -153,7 +153,7 @@ jobs:
|
||||
with:
|
||||
path: |
|
||||
cache.tar.xz
|
||||
key: gam-${{ matrix.jid }}-20251218
|
||||
key: gam-${{ matrix.jid }}-20260213
|
||||
|
||||
- name: Untar Cache archive
|
||||
if: matrix.goal == 'build' && steps.cache-python-ssl.outputs.cache-hit == 'true'
|
||||
@@ -507,6 +507,8 @@ jobs:
|
||||
"$PYTHON" -m pip list
|
||||
|
||||
- name: Install pip requirements
|
||||
env:
|
||||
GH_TOKEN: ${{ github.token }}
|
||||
run: |
|
||||
echo "before anything..."
|
||||
"$PYTHON" -m pip list
|
||||
@@ -517,6 +519,12 @@ jobs:
|
||||
echo "--pip debug verbose--"
|
||||
"$PYTHON" -m pip debug --verbose
|
||||
echo "--------"
|
||||
if ([ "$RUNNER_OS" == "Windows" ] && [ "$RUNNER_ARCH" == "ARM64" ]); then
|
||||
# custom cryptography wheel for win arm64 since the project doesn't provide one:
|
||||
# https://github.com/pyca/cryptography/issues/14293
|
||||
gh release download --repo "jay0lee/cryptography-wheels" --pattern "*win_arm64.whl" --clobber
|
||||
"$PYTHON" -m pip install cryptography-*.whl
|
||||
fi
|
||||
"$PYTHON" -m pip install -vvv --upgrade ..[yubikey]
|
||||
echo "after everything..."
|
||||
"$PYTHON" -m pip list
|
||||
@@ -625,13 +633,19 @@ jobs:
|
||||
- name: MacOS send GAM binary for Apple notarization
|
||||
if: runner.os == 'macOS'
|
||||
env:
|
||||
ASP_NOTARIZE: ${{ secrets.ASP_NOTARIZE }}
|
||||
APPLE_KEY: ${{ secrets.APPLE_KEY }}
|
||||
APPLE_KEY_ID: ${{ secrets.APPLE_KEY_ID }}
|
||||
APPLE_ISSUER_ID: ${{ secrets.APPLE_ISSUER_ID }}
|
||||
run: |
|
||||
# Apple wants some kind of "package" submitted so just add gam to a .zip
|
||||
# name it something we can track and link in Apple's notarize process
|
||||
zipfilename="./gam-${RUNNER_ARCH}-${GITHUB_RUN_ID}-${GITHUB_RUN_NUMBER}.zip"
|
||||
zip -r "$zipfilename" "$gampath"
|
||||
xcrun notarytool submit --apple-id "jay0lee@gmail.com" --password "$ASP_NOTARIZE" --team-id GZ85H2DRLM "$zipfilename"
|
||||
export KEY_FILE="$(mktemp).p8"
|
||||
trap 'rm -f "$KEY_FILE"' EXIT
|
||||
echo "$APPLE_KEY" > "$KEY_FILE"
|
||||
xcrun notarytool submit "$zipfilename" --key "$KEY_FILE" --key-id "$APPLE_KEY_ID" --issuer "$APPLE_ISSUER_ID"
|
||||
rm -v "$KEY_FILE"
|
||||
rm -v "$zipfilename"
|
||||
|
||||
- name: Basic Tests all jobs
|
||||
@@ -669,10 +683,9 @@ jobs:
|
||||
if: runner.os == 'Windows'
|
||||
shell: pwsh
|
||||
run: |
|
||||
#$url = "https://files.certum.eu/software/SimplySignDesktop/Windows/9.3.2.67/SimplySignDesktop-9.3.2.67-64-bit-en.msi"
|
||||
#$file = "SimplySignDesktop-9.3.2.67-64-bit-en.msi"
|
||||
$url = "https://files.certum.eu/software/SimplySignDesktop/Windows/9.3.4.72/SimplySignDesktop-9.3.4.72-64-bit-en.msi"
|
||||
$file = "SimplySignDesktop-9.3.4.72-64-bit-en.msi"
|
||||
#$url = "https://files.certum.eu/software/SimplySignDesktop/Windows/9.3.4.72/SimplySignDesktop-9.3.4.72-64-bit-en.msi"
|
||||
$url = "https://www.files.certum.eu/software/SimplySignDesktop/Windows/9.4.0.84/SimplySignDesktop-9.4.0.84-64-bit-en.msi"
|
||||
$file = "SimplySignDesktop.msi"
|
||||
Invoke-WebRequest $url -OutFile $file
|
||||
$log = "install.log"
|
||||
$procMain = Start-Process "msiexec" "/i `"$file`" /qn /l*! `"$log`"" -NoNewWindow -PassThru
|
||||
|
||||
@@ -12,7 +12,7 @@ authors = [
|
||||
dependencies = [
|
||||
"arrow>=1.3.0",
|
||||
"chardet>=5.2.0",
|
||||
"cryptography>=44.0.2",
|
||||
"cryptography>=46.0.5",
|
||||
"distro; sys_platform=='linux'",
|
||||
"filelock>=3.18.0",
|
||||
"google-api-python-client>=2.167.0",
|
||||
|
||||
@@ -386,6 +386,8 @@ If an item contains spaces, it should be surrounded by ".
|
||||
<ChatEmoji> ::= emojiname <ChatEmojiName> | customemojis/<String>
|
||||
<ChatMember> ::= spaces/<String>/members/<String>
|
||||
<ChatMessage> ::= spaces/<String>/messages/<String>
|
||||
<ChatSection> ::= users/<String>/sections/<String> | sections/<String> | section <String>
|
||||
<ChatSectionItem> ::= users/<String>/sections/<String>/items/<String> | sections/<String>/items/<String>
|
||||
<ChatSpace> ::= spaces/<String> | space <String> | space spaces/<String>
|
||||
<ChatThread> ::= spaces/<String>/threads/<String>
|
||||
<ChromeProfilePermanentID> ::= <String>
|
||||
@@ -512,6 +514,8 @@ If an item contains spaces, it should be surrounded by ".
|
||||
<MatterItem> ::= <UniqueID>|<String>
|
||||
<MatterState> ::= open|closed|deleted
|
||||
<MeetConferenceName> ::= conferenceRecords/<String>
|
||||
<MeetID> ::= <String>
|
||||
Must match this Python Regular Expression: [a-z]{3}-[a-z]{4}-[a-z]{3}
|
||||
<MeetSpaceName> ::= spaces/<String> | <String>
|
||||
<MessageContent> ::=
|
||||
(message|textmessage|htmlmessage <String>)|
|
||||
@@ -527,6 +531,7 @@ If an item contains spaces, it should be surrounded by ".
|
||||
(gdoc|ghtml <UserGoogleDoc>)|
|
||||
(gcsdoc|gcshtml <StorageBucketObjectName>)
|
||||
<NumberOfSeats> ::= <Number>
|
||||
<NumberRange> ::= <Number>|(<Number>/<Number>)
|
||||
<OrgUnitID> ::= id:<String>
|
||||
<OrgUnitPath> ::= /|(/<String>)+
|
||||
<OrgUnitItem> ::= <OrgUnitID>|<OrgUnitPath>
|
||||
@@ -764,6 +769,7 @@ If an item contains spaces, it should be surrounded by ".
|
||||
<MimeTypeNameList> ::= "<MimeTypeName>(,<MimeTypeName>)*"
|
||||
<NamespaceList> ::= "<Namespace>(,<Namespace>)*"
|
||||
<NotesNameList> ::= "<NotesName>(,<NotesName>)*"
|
||||
<NumberRangeList> ::= "<NumberRange>(,<NumberRange>)*"
|
||||
<OrgUnitList> ::= "<OrgUnitItem>(,<OrgUnitItem>)*"
|
||||
<OtherContactsResourceNameList> ::= "<OtherContactsResourceName>(,<OtherContactsResourceName>)*"
|
||||
<PeopleResourceNameList> ::= "<PeopleResourceName>(,<PeopleResourceName>)*"
|
||||
@@ -1286,11 +1292,12 @@ Specify a collection of items by directly specifying them; the item type is dete
|
||||
|
||||
## Select a section from gam.cfg and process a GAM command using values from that section
|
||||
<Select> ::=
|
||||
select <Section> [save] [verify]
|
||||
select <Section> [save] [verify [variables <RESearchPattern>]]
|
||||
save
|
||||
Set section = <Section> in the [DEFAULT] section and write configuration data to gam.cfg
|
||||
verify
|
||||
Print the variable values for the selected section
|
||||
Use `variables <RESearchPattern>` to display variables with names selected by `<RESearchPattern>`
|
||||
Values are determined in this order: Selected section, DEFAULT section, Program default
|
||||
|
||||
## Display all of the sections in gam.cfg and mark the currently selected section with a *.
|
||||
@@ -1314,7 +1321,7 @@ csv_input_row_drop_filter, csv_input_row_drop_filter_mode and csv_input_row_limi
|
||||
## Set variables in gam.cfg.
|
||||
|
||||
<Config> ::=
|
||||
config (<VariableName> [=] <Value>)* [save] [verify]
|
||||
config (<VariableName> [=] <Value>)* [save] [verify [variables <RESearchPattern>]]
|
||||
<VariableName> [=] <Value>
|
||||
Set <VariableName> = <Value> in the current section
|
||||
All <VariableNames> except section are allowed.
|
||||
@@ -1323,6 +1330,7 @@ save
|
||||
Write configuration data to gam.cfg
|
||||
verify
|
||||
Print the variable values for the current section
|
||||
Use `variables <RESearchPattern>` to display variables with names selected by `<RESearchPattern>`.
|
||||
Values are determined in this order: Current section, DEFAULT section, Program default
|
||||
|
||||
## Terminate processing of a CSV or batch file when one of the subprocesses returns a matching return code.
|
||||
@@ -1821,8 +1829,10 @@ gam calendar|calendars <CalendarEntity> import event icaluid <iCalUID> <EventImp
|
||||
gam calendar|calendars <CalendarEntity> update events [<EventEntity>] [replacemode] <EventUpdateAttribute>+ [<EventNotificationAttribute>]
|
||||
[showdayofweek]
|
||||
[csv [todrive <ToDriveAttribute>*] [formatjson [quotechar <Character>]]]
|
||||
gam calendar|calendars <CalendarEntity> delete events [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam calendar|calendars <CalendarEntity> purge events [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam calendar|calendars <CalendarEntity> delete events [<EventEntity>]
|
||||
# [batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
gam calendar|calendars <CalendarEntity> purge events [<EventEntity>]
|
||||
# [batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
gam calendar|calendars <CalendarEntity> wipe events
|
||||
gam calendar|calendars <CalendarEntity> move events [<EventEntity>] destination|to <CalendarItem> [<EventNotificationAttribute>]
|
||||
gam calendar|calendars <CalendarEntity> empty calendartrash
|
||||
@@ -1945,7 +1955,7 @@ gam calendar|calendars <CalendarEntity> show events [<EventEntity>] <EventDispla
|
||||
[fields <EventFieldNameList>] [showdayofweek]
|
||||
[countsonly|formatjson]
|
||||
gam calendar|calendars <CalendarEntity> print events [<EventEntity>] <EventDisplayProperty>*
|
||||
[fields <EventFieldNameList>] [showdayofweek]
|
||||
[fields <EventFieldNameList>] [showdayofweek] [attendeeslist]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
[eventrowfilter]
|
||||
[countsonly|(formatjson [quotechar <Character>])] [todrive <ToDriveAttribute>*]
|
||||
@@ -2461,10 +2471,18 @@ gam <CrOSTypeEntity> update action <CrOSAction> [acknowledge_device_touch_requir
|
||||
wipe_users|
|
||||
take_a_screenshot
|
||||
|
||||
gam issuecommand cros <CrOSEntity> command <CrOSCommand> [times_to_check_status <Integer>] [doit]
|
||||
gam <CrOSTypeEntity> issuecommand command <CrOSCommand> [times_to_check_status <Integer>] [doit]
|
||||
gam getcommand cros <CrOSEntity> commandid <CommandID> [times_to_check_status <Integer>]
|
||||
gam <CrOSTypeEntity> getcommand commandid <CommandID> [times_to_check_status <Integer>]
|
||||
gam issuecommand cros <CrOSEntity> command <CrOSCommand>
|
||||
[times_to_check_status <Integer>] [doit]
|
||||
[csv (addcsvdata <FieldName> <String>)*]
|
||||
gam <CrOSTypeEntity> issuecommand command <CrOSCommand>
|
||||
[times_to_check_status <Integer>] [doit]
|
||||
[csv (addcsvdata <FieldName> <String>)*]
|
||||
gam getcommand cros <CrOSEntity> commandid <CommandID>
|
||||
[times_to_check_status <Integer>]
|
||||
[csv (addcsvdata <FieldName> <String>)*]
|
||||
gam <CrOSTypeEntity> getcommand commandid <CommandID>
|
||||
[times_to_check_status <Integer>]
|
||||
[csv (addcsvdata <FieldName> <String>)*]
|
||||
|
||||
<CrOSAttribute> ::=
|
||||
(asset|assetid|tag <String>)|
|
||||
@@ -2577,7 +2595,7 @@ gam print cros [todrive <ToDriveAttribute>*]
|
||||
[start <Date>] [end <Date>] [listlimit <Number>]
|
||||
[reverselists <CrOSListFieldNameList>]
|
||||
[timerangeorder ascending|descending] [showdvrsfp]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[sortheaders]
|
||||
[formatjson [quotechar <Character>]]
|
||||
[showitemcountonly]
|
||||
@@ -2591,6 +2609,7 @@ gam print cros [todrive <ToDriveAttribute>*] select <CrOSTypeEntity>
|
||||
[start <Date>] [end <Date>] [listlimit <Number>]
|
||||
[reverselists <CrOSListFieldNameList>]
|
||||
[timerangeorder ascending|descending] [showdvrsfp]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[sortheaders]
|
||||
[formatjson [quotechar <Character>]]
|
||||
[showitemcountonly]
|
||||
@@ -2602,7 +2621,7 @@ gam <CrOSTypeEntity> print cros [todrive <ToDriveAttribute>*]
|
||||
[start <Date>] [end <Date>] [listlimit <Number>]
|
||||
[reverselists <CrOSListFieldNameList>]
|
||||
[timerangeorder ascending|descending] [showdvrsfp]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[sortheaders]
|
||||
[formatjson [quotechar <Character>]]
|
||||
[showitemcountonly]
|
||||
@@ -2770,21 +2789,23 @@ gam create chromepolicyimage <ChromePolicyImageSchemaName> <FileName>
|
||||
|
||||
gam update chromepolicy [convertcrnl]
|
||||
(<SchemaName> ((<Field> <Value>)+ | <JSONData>))+
|
||||
((ou|orgunit <OrgUnitItem>)|(cigroup <GroupItem>))
|
||||
((ou|orgunit <OrgUnitItem>)|(group <GroupItem>))
|
||||
[(printerid <PrinterID>)|(appid <AppID>)]
|
||||
gam delete chromepolicy
|
||||
(<SchemaName> [<JSONData>])+
|
||||
((ou|orgunit <OrgUnitItem>)|(cigroup <GroupItem>))
|
||||
((ou|orgunit <OrgUnitItem>)|(group <GroupItem>))
|
||||
[(printerid <PrinterID>)|(appid <AppID>)]
|
||||
gam show chromepolicies
|
||||
((ou|orgunit <OrgUnitItem> [show all|direct|inherited])|(cigroup <GroupItem>))
|
||||
((ou|orgunit <OrgUnitItem> [show all|direct|inherited])|(group <GroupItem>))
|
||||
[(printerid <PrinterID>)|(appid <AppID>)]
|
||||
(filter <StringList>)* (namespace <NamespaceList>)*
|
||||
[show all|direct|inherited]
|
||||
[formatjson]
|
||||
gam print chromepolicies [todrive <ToDriveAttribute>*]
|
||||
((ou|orgunit <OrgUnitItem> [show all|direct|inherited])|(cigroup <GroupItem>))
|
||||
((ou|orgunit <OrgUnitItem> [show all|direct|inherited])|(group <GroupItem>))
|
||||
[(printerid <PrinterID>)|(appid <AppID>)]
|
||||
(filter <StringList>)* (namespace <NamespaceList>)*
|
||||
[show all|direct|inherited] [shownopolicy]
|
||||
[[formatjson [quotechar <Character>]]
|
||||
|
||||
<ChromePolicySchemaFieldName> ::=
|
||||
@@ -3980,7 +4001,7 @@ gam info group|groups <GroupEntity>
|
||||
[basic] <GroupFieldName>* [fields <GroupFieldNameList>] [nodeprecated]
|
||||
[ciallfields|(cifields <CIGroupFieldNameList>)]
|
||||
[members] [managers] [owners]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
[types <GroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
@@ -3998,12 +4019,13 @@ gam print groups [todrive <ToDriveAttribute>*]
|
||||
[nodeprecated]
|
||||
[roles <GroupRoleList>]
|
||||
[members|memberscount] [managers|managerscount] [owners|ownerscount] [totalcount] [countsonly]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[includederivedmembership]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
[types <GroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[convertcrnl] [delimiter <Character>] [sortheaders]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
[showitemcountonly]
|
||||
|
||||
@@ -4034,7 +4056,8 @@ gam print group-members [todrive <ToDriveAttribute>*]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[admincreatedmatch <Boolean>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[showallowexternal [<Boolean>]] [verifyallowexternal [<Boolean>]]
|
||||
[membernames] [showdeliverysettings]
|
||||
<MembersFieldName>* [fields <MembersFieldNameList>]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
@@ -4045,8 +4068,9 @@ gam print group-members [todrive <ToDriveAttribute>*]
|
||||
[(recursive [noduplicates])|includederivedmembership] [nogroupemail]
|
||||
[peoplelookup|(peoplelookupuser <EmailAddress>)]
|
||||
[unknownname <String>] [cachememberinfo [Boolean]]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
`gam show group-members
|
||||
gam show group-members
|
||||
[([domain|domains <DomainNameEntity>] ([member|showownedby <EmailItem>]|[(query <QueryGroup>)|(queries <QueryGroupList>)]))|
|
||||
(group|group_ns|group_susp <GroupItem>)|
|
||||
(select <GroupEntity>)]
|
||||
@@ -4054,7 +4078,7 @@ gam print group-members [todrive <ToDriveAttribute>*]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[admincreatedmatch <Boolean>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners] [depth <Number>]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
[types <GroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
@@ -4122,7 +4146,7 @@ gam info cigroups <GroupEntity>
|
||||
[nosecurity|nosecuritysettings]
|
||||
[allfields|<CIGroupFieldName>*|(fields <CIGroupFieldNameList>)]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[formatjson]
|
||||
@@ -4134,10 +4158,11 @@ gam print cigroups [todrive <ToDriveAttribute>*]
|
||||
[basic|allfields|(<CIGroupFieldName>* [fields <CIGroupFieldNameList>])]
|
||||
[roles <GroupRoleList>] [memberrestrictions]
|
||||
[members|memberscount] [managers|managerscount] [owners|ownerscount] [totalcount] [countsonly]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[convertcrnl] [delimiter <Character>]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
[showitemcountonly]
|
||||
|
||||
@@ -4161,11 +4186,14 @@ gam print cigroup-members [todrive <ToDriveAttribute>*]
|
||||
[emailmatchpattern [not] <REMatchPattern>] [namematchpattern [not] <REMatchPattern>]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[showallowexternal [<Boolean>]] [verifyallowexternal [<Boolean>]]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
<CIGroupMembersFieldName>* [fields <CIGroupMembersFieldNameList>]
|
||||
[minimal|basic|full]
|
||||
[(recursive [noduplicates]) | includederivedmembership] [nogroupemail]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
gam show cigroup-members
|
||||
[(cimember|ciowner <UserItem>)|(cigroup <GroupItem>)|(select <GroupEntity>)]
|
||||
@@ -4173,6 +4201,7 @@ gam show cigroup-members
|
||||
[emailmatchpattern [not] <REMatchPattern>] [namematchpattern [not] <REMatchPattern>]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[minimal|basic|full]
|
||||
@@ -4301,7 +4330,7 @@ gam update deviceuserstate <DeviceUserEntity> [clientid <String>]
|
||||
[customid <String>] [assettags clear|<AssetTagList>]
|
||||
[compliantstate|compliancestate compliant|noncompliant] [managedstate clear|managed|unmanaged]
|
||||
[healthscore very_poor|poor|neutral|good|very_good] [scorereason clear|<String>]
|
||||
(customvalue (bool|boolean <Boolean>)|(number <Integer>)|(string <String>))*
|
||||
(customvalue clear|(bool|boolean <String> <Boolean>)|(number <String> <Integer>)|(string <String> <String>))*
|
||||
|
||||
# Cloud Identity Policies
|
||||
|
||||
@@ -4585,39 +4614,55 @@ gam report usage customer [todrive <ToDriveAttribute>*]
|
||||
[convertmbtogb]
|
||||
|
||||
<ActivityApplicationName> ::=
|
||||
accessevaluation|
|
||||
accesstransparency|access|
|
||||
admin|
|
||||
admindataaction|
|
||||
assignments|
|
||||
calendar|calendars|
|
||||
chat|
|
||||
chrome|
|
||||
classroom|
|
||||
cloudsearch|
|
||||
contacts|
|
||||
contextawareaccess|
|
||||
datamigration|
|
||||
datastudio|
|
||||
directorysync|
|
||||
drive|doc|docs|
|
||||
gcp|cloud|
|
||||
geminiinworkspaceapps|gemini|geminiforworkspace|
|
||||
gmail|
|
||||
gplus|currents|google+|
|
||||
graduation|
|
||||
groups|group|
|
||||
groupsenterprise|enterprisegroups|
|
||||
jamboard|
|
||||
keep|
|
||||
ldap|
|
||||
login|logins|
|
||||
meet|hangoutsmeet|
|
||||
meethardware|
|
||||
mobile|devices|
|
||||
profile|
|
||||
rules|
|
||||
saml|
|
||||
takeout|
|
||||
tasks|
|
||||
token|tokens|oauthtoken|
|
||||
useraccounts|
|
||||
vault
|
||||
|
||||
gam report <ActivityApplicationName> [todrive <ToDriveAttribute>*]
|
||||
[(user all|<UserItem>)|(orgunit|org|ou <OrgUnitPath> [showorgunit])|(select <UserTypeEntity>)]
|
||||
[userisactor]
|
||||
[([start <Time>] [end <Time>])|(range <Time> <Time>)|
|
||||
yesterday|today|thismonth|(previousmonths <Integer>)]
|
||||
[filter <String> (filtertime<String> <Time>)*]
|
||||
[event|events <EventNameList>] [ip <String>]
|
||||
[groupidfilter <String>]
|
||||
[gmaileventtypes <NumberRangeList>]
|
||||
[groupidfilter <String>] [resourcedetailsfilter <String>]
|
||||
[notimesort]
|
||||
[maxactivities <Number>] [maxevents <Number>] [maxresults <Number>]
|
||||
[countsonly [bydate|summary] [eventrowfilter]]
|
||||
(addcsvdata <FieldName> <String>)* [shownoactivities]
|
||||
@@ -5425,7 +5470,7 @@ gam print vaultcounts [todrive <ToDriveAttributes>*]
|
||||
[wait <Integer>]
|
||||
gam print vaultcounts [todrive <ToDriveAttributes>*]
|
||||
matter <MatterItem>
|
||||
corpus mail|groups
|
||||
corpus mail|groups
|
||||
[scope [all_data|held_data|unprocessed_data]]
|
||||
[(accounts <EmailAddressEntity>) | (orgunit|org|ou <OrgUnitPath>) | everyone]
|
||||
[terms <String>] [start|starttime <Date>|<Time>] [end|endtime <Date>|<Time>] [timezone <TimeZone>]
|
||||
@@ -5587,7 +5632,7 @@ gam create vaultquery <MatterItem> [name <String>]
|
||||
[locationquery <StringList>] [peoplequery <StringList>] [minuswords <StringList>]
|
||||
[responsestatuses <AttendeeStatus>(,<AttendeeStatus>)*] [calendarversiondate <Date>|<Time>]
|
||||
(covereddata calllogs|textmessages|voicemails)*
|
||||
[<JSONData>]
|
||||
[<JSONData>]
|
||||
[shownames]
|
||||
[showdetails|returnidonly|formatjson]
|
||||
|
||||
@@ -5922,7 +5967,7 @@ gam print users [todrive <ToDriveAttribute>*]
|
||||
[delimiter <Character>] [sortheaders [<Boolean>]] [scalarsfirst [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]] [quoteplusphonenumbers]
|
||||
[issuspended <Boolean>] [isarchived <Boolean>] [aliasmatchpattern <REMatchPattern>]
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)*
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[showitemcountonly]
|
||||
|
||||
Print fields for specified users.
|
||||
@@ -5939,7 +5984,7 @@ gam print users [todrive <ToDriveAttribute>*] select <UserTypeEntity>
|
||||
[delimiter <Character>] [sortheaders [<Boolean>]] [scalarsfirst [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]] [quoteplusphonenumbers]
|
||||
[issuspended <Boolean>] [isarchived <Boolean>] [aliasmatchpattern <REMatchPattern>]
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)*
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[showitemcountonly]
|
||||
|
||||
gam <UserTypeEntity> print users [todrive <ToDriveAttribute>*]
|
||||
@@ -5954,7 +5999,7 @@ gam <UserTypeEntity> print users [todrive <ToDriveAttribute>*]
|
||||
[delimiter <Character>] [sortheaders [<Boolean>]] [scalarsfirst [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]] [quoteplusphonenumbers]
|
||||
[issuspended <Boolean>] [isarchived <Boolean>] [aliasmatchpattern <REMatchPattern>]
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)*
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[showitemcountonly]
|
||||
|
||||
The first column will always be primaryEmail; the remaining field names will be sorted if allfields, basic, full or sortheaders is specified;
|
||||
@@ -6124,6 +6169,7 @@ Display a users calendar settings
|
||||
defaulteventlength|
|
||||
format24hourtime|
|
||||
hideinvitations|
|
||||
hideinvitationssetting|
|
||||
hideweekends|
|
||||
locale|
|
||||
remindonrespondedeventsonly|
|
||||
@@ -6308,8 +6354,10 @@ gam <UserTypeEntity> import event <UserCalendarEntity> icaluid <iCalUID> <EventI
|
||||
gam <UserTypeEntity> update events <UserCalendarEntity> [<EventEntity>] [replacemode] <EventUpdateAttribute>+ [<EventNotificationAttribute>]
|
||||
[showdayofweek]
|
||||
[csv [todrive <ToDriveAttribute>*] [formatjson [quotechar <Character>]]]
|
||||
gam <UserTypeEntity> delete events <UserCalendarEntity> [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> purge events <UserCalendarEntity> [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> delete events <UserCalendarEntity> [<EventEntity>]
|
||||
# [batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> purge events <UserCalendarEntity> [<EventEntity>]
|
||||
# [batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> wipe events <UserCalendarEntity>
|
||||
gam <UserTypeEntity> move events <UserCalendarEntity> [<EventEntity>] destination|to <CalendarItem> [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> empty calendartrash <UserCalendarEntity>
|
||||
@@ -6328,7 +6376,7 @@ gam <UserTypeEntity> show events <UserCalendarEntity> [<EventEntity>] <EventDisp
|
||||
[fields <EventFieldNameList>] [showdayofweek]
|
||||
[countsonly|formatjson]
|
||||
gam <UserTypeEntity> print events <UserCalendarEntity> [<EventEntity>] <EventDisplayProperty>*
|
||||
[fields <EventFieldNameList>] [showdayofweek]
|
||||
[fields <EventFieldNameList>] [showdayofweek] [attendeeslist]
|
||||
[eventrowfilter]]
|
||||
[countsonly|(formatjson [quotechar <Character>])] [todrive <ToDriveAttribute>*]
|
||||
|
||||
@@ -6513,6 +6561,26 @@ gam <UserItem> print chatspaces asadmin [todrive <ToDriveAttribute>*]
|
||||
[fields <ChatSpaceFieldNameList>] [showaccessssettings]
|
||||
[formatjson [quotechar <Character>]]
|
||||
|
||||
gam <UserTypeEntity> create chatsection
|
||||
displayname <String>
|
||||
[formatjson|returnidonly]
|
||||
gam <UserTypeEntity> update chatsection <ChatSection>
|
||||
[displayname <String>]
|
||||
[(sortorder <Integer>)|(position start|end)]
|
||||
[formatjson]
|
||||
gam <UserTypeEntity> delete chatsection <ChatSection>
|
||||
gam <UserTypeEntity> show chatsections
|
||||
[formatjson]
|
||||
gam <UserTypeEntity> print chatsections [todrive <ToDriveAttribute>*]
|
||||
[formatjson [quotechar <Character>]]
|
||||
gam <UserTypeEntity> move chatsectionitem <ChatSectionItem> to <ChatSection>
|
||||
gam <UserTypeEntity> show chatsectionitems <ChatSection>
|
||||
[space <ChatSpace>]
|
||||
[formatjson]
|
||||
gam <UserTypeEntity> print chatsectionitems <ChatSection> [todrive <ToDriveAttribute>*]
|
||||
[space <ChatSpace>]
|
||||
[formatjson [quotechar <Character>]]
|
||||
|
||||
gam <UserTypeEntity> create chatmember <ChatSpace>
|
||||
[type human|bot] [role member|manager|owner]
|
||||
(user <UserItem>)* (members <UserTypeEntity>)*
|
||||
@@ -6823,8 +6891,14 @@ gam <UserTypeEntity> copy drivefile <DriveFileEntity>
|
||||
<DriveFileCopyAttribute>*
|
||||
[skipids <DriveFileEntity>]
|
||||
[copysubfiles [<Boolean>]] [filenamematchpattern <REMatchPattern>]
|
||||
[filemimetype [not] <MimeTypeList>]
|
||||
[copysubfilesownedby any|me|others]
|
||||
[filemimetype [not] <MimeTypeList>] [filemimetype category <MimeTypeNameList>]
|
||||
[([start|starttime <Date>|<Time>] [end|endtime <Date>|<Time>])|(range <Date>|<Time> <Date>|<Time>)]|
|
||||
[copysubfilesownedby
|
||||
any|me|others|
|
||||
users <EmailAddressList>|
|
||||
notusers <EmailAddressList>|
|
||||
regex <REMatchPattern>|
|
||||
notregex <REMatchPattern>]
|
||||
[copysubfolders [<Boolean>]] [foldernamematchpattern <REMatchPattern>]
|
||||
[copysubshortcuts [<Boolean>]] [shortcutnamematchpattern <REMatchPattern>]
|
||||
[duplicatefiles overwriteolder|overwriteall|duplicatename|uniquename|skip]
|
||||
@@ -6833,6 +6907,7 @@ gam <UserTypeEntity> copy drivefile <DriveFileEntity>
|
||||
[copyfilepermissions [<Boolean>]]
|
||||
[copyfileinheritedpermissions [<Boolean>]
|
||||
[copyfilenoninheritedpermissions [<Boolean>]
|
||||
[copyfolderpermissions [<Boolean>]]
|
||||
[copymergewithparentfolderpermissions [<Boolean>]]
|
||||
[copymergedtopfolderpermissions [<Boolean>]]
|
||||
[copytopfolderpermissions [<Boolean>]]
|
||||
@@ -6862,6 +6937,7 @@ gam <UserTypeEntity> move drivefile <DriveFileEntity> [newfilename <DriveFileNam
|
||||
[createshortcutsfornonmovablefiles [<Boolean>]]
|
||||
[duplicatefiles overwriteolder|overwriteall|duplicatename|uniquename|skip]
|
||||
[duplicatefolders merge|duplicatename|uniquename|skip]
|
||||
[copyfolderpermissions [<Boolean>]]
|
||||
[copymergewithparentfolderpermissions [<Boolean>]]
|
||||
[copymergedtopfolderpermissions [<Boolean>]]
|
||||
[copytopfolderpermissions [<Boolean>]]
|
||||
@@ -6904,6 +6980,7 @@ gam <UserTypeEntity> info drivefile <DriveFileEntity>
|
||||
[returnidonly]
|
||||
[filepath|fullpath] [folderpathonly [<Boolean>]] [pathdelimiter <Character>]
|
||||
[allfields|<DriveFieldName>*|(fields <DriveFieldNameList>)]
|
||||
[includepermissionsforview published]
|
||||
(orderby <DriveFileOrderByFieldName> [ascending|descending])*
|
||||
[showdrivename] [showshareddrivepermissions]
|
||||
[(showlabels details|ids)|(includelabels <ClassificationLabelIDList>)]
|
||||
@@ -7387,6 +7464,7 @@ gam <UserTypeEntity> show fileinfo <DriveFileEntity>
|
||||
[returnidonly]
|
||||
[filepath|fullpath] [folderpathonly [<Boolean>]] [pathdelimiter <Character>]
|
||||
[allfields|<DriveFieldName>*|(fields <DriveFieldNameList>)]
|
||||
[includepermissionsforview published]
|
||||
(orderby <DriveFileOrderByFieldName> [ascending|descending])*
|
||||
[showdrivename] [showshareddrivepermissions]
|
||||
[(showlabels details|ids)|(includelabels <ClassificationLabelIDList>)]
|
||||
@@ -7440,11 +7518,11 @@ gam <UserTypeEntity> show filecounts
|
||||
|
||||
gam <UserTypeEntity> print filesharecounts [todrive <ToDriveAttribute>*]
|
||||
[excludetrashed]
|
||||
[internaldomains <DomainNameList>]
|
||||
[internaldomains all|primary|<DomainNameList>]
|
||||
[summary none|only|plus] [summaryuser <String>]
|
||||
gam <UserTypeEntity> show filesharecounts
|
||||
[excludetrashed]
|
||||
[internaldomains <DomainNameList>]
|
||||
[internaldomains all|primary|<DomainNameList>]
|
||||
[summary none|only|plus] [summaryuser <String>]
|
||||
|
||||
<FileTreeFieldName> ::=
|
||||
@@ -7500,6 +7578,7 @@ gam <UserTypeEntity> print filelist [todrive <ToDriveAttribute>*]
|
||||
[sizefield quotabytesused|size] [minimumfilesize <Integer>] [maximumfilesize <Integer>]
|
||||
[filenamematchpattern <REMatchPattern>]
|
||||
<PermissionMatch>* [<PermissionMatchMode>] [<PermissionMatchAction>] [pmfilter] [oneitemperrow]
|
||||
[includepermissionsforview published]
|
||||
[excludetrashed]
|
||||
[maxfiles <Integer>] [nodataheaders <String>]
|
||||
[countsonly [summary none|only|plus] [summaryuser <String>]
|
||||
@@ -7512,7 +7591,7 @@ gam <UserTypeEntity> print filelist [todrive <ToDriveAttribute>*]
|
||||
[showparentsidsaslist] [showpermissionslast]
|
||||
(orderby <DriveFileOrderByFieldName> [ascending|descending])* [delimiter <Character>]
|
||||
[stripcrsfromname]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
|
||||
gam <UserTypeEntity> print diskusage <DriveFileEntity> [todrive <ToDriveAttribute>*]
|
||||
@@ -7971,7 +8050,7 @@ gam <UserTypeEntity> signature|sig
|
||||
[html [<Boolean>]] [replyto <EmailAddress>] [default] [treatasalias <Boolean>]
|
||||
[name <String>]
|
||||
[primary]
|
||||
gam <UserTypeEntity> show signature|sig [compact|format|html]
|
||||
gam <UserTypeEntity> show signature|sig [compact|format|html|template]
|
||||
[primary|default] [verifyonly]
|
||||
gam <UserTypeEntity> print signature [compact]
|
||||
[primary|default] [verifyonly] [todrive <ToDriveAttribute>*]
|
||||
@@ -8286,7 +8365,7 @@ gam <UserItem> print meettranscripts <MeetConferenceName> [todrive <ToDriveAttri
|
||||
|
||||
<BiographyContent> ::=
|
||||
<String>|
|
||||
(file|textfile <FileName> [charset <Charset>])|
|
||||
(file|textfile <FileName> [charset <Charset>])|
|
||||
(gdoc <UserGoogleDoc>)
|
||||
|
||||
<PeopleContactAttribute> ::=
|
||||
|
||||
@@ -1,3 +1,352 @@
|
||||
7.34.06
|
||||
|
||||
Added option `copyfolderpermissions [<Boolean>]` to `gam <UserTypeEntity> copy|move drivefile`.
|
||||
|
||||
When `copyfolderpermissions false` is specified, no folder permissions are copied; this simplifies
|
||||
disabling all folder permission copying.
|
||||
|
||||
When not specified or `copyfolderpermissions [true]` is specified, folder permissions are copied based on the following options:
|
||||
```
|
||||
copymergewithparentfolderpermissions [<Boolean>]
|
||||
copymergedtopfolderpermissions [<Boolean>]
|
||||
copytopfolderpermissions [<Boolean>]
|
||||
copytopfolderiheritedpermissions [<Boolean>]
|
||||
copytopfoldernoniheritedpermissions never|always|syncallfolders|syncupdatedfolders
|
||||
copymergedsubfolderpermissions [<Boolean>]
|
||||
copysubfolderpermissions [<Boolean>]
|
||||
copysubfolderinheritedpermissions [<Boolean>]
|
||||
copysubfoldernoniheritedpermissions never|always|syncallfolders|syncupdatedfolders
|
||||
```
|
||||
|
||||
7.34.05
|
||||
|
||||
Updated `gam report <ActivityApplictionName>` to perform a reverse chronological sort
|
||||
on all rows across multiple users and/or event names; this is consistent with the behavior
|
||||
in the Admin console. Use option `notimesort` to suppress this sort.
|
||||
|
||||
7.34.04
|
||||
|
||||
Updated `gam <UserTypeEntity> create drivefileacl <DriveFileEntity> user <UserItem> role owner` to better
|
||||
handle the case where the current owner of a file is suspended. Previously, the command was displayed as an error
|
||||
even though the ownership was changed.
|
||||
```
|
||||
gam user currentowner@domain.com add drivefileacl <DriveFileID> user newowner@domain.com role owner
|
||||
User: currentowner@domain.com, Add 1 Drive File/Folder ACL
|
||||
User: currentowner@domain.com, Drive File/Folder ID: <DriveFileID>, Permission ID: newowner@domain.com, Add Failed: Sorry, the items were successfully shared but emails could not be sent to newowner@domain.com.
|
||||
```
|
||||
|
||||
Now the command is displayed as a success with a note indicating that the ownership change email was not sent.
|
||||
```
|
||||
gam user currentowner@domain.com add drivefileacl <DriveFileID> user newowner@domain.com role owner
|
||||
User: currentowner@domain.com, Add 1 Drive File/Folder ACL
|
||||
User: currentowner@domain.com, Drive File/Folder ID: <DriveFileID>, Permission ID: newowner@domain.com, Added: Sorry, the items were successfully shared but emails could not be sent to newowner@domain.com.
|
||||
New Owner
|
||||
id: 10834698115409747890
|
||||
type: user
|
||||
emailAddress: newowner@domain.com
|
||||
domain: domain.com
|
||||
role: owner
|
||||
permissionDetails:
|
||||
role: writer
|
||||
type: file
|
||||
inherited: True
|
||||
inheritedFrom: Unknown
|
||||
role: owner
|
||||
type: file
|
||||
inherited: False
|
||||
deleted: False
|
||||
pendingOwner: False
|
||||
```
|
||||
|
||||
7.34.03
|
||||
|
||||
Updated to Python 3.14.3
|
||||
|
||||
Updated Cryptography to 46.0.5
|
||||
|
||||
Updated `gam course <CourseID> create student|teacher <EmailAddress>` error message when
|
||||
`<EmailAddress>` is not in a trusted domain to remove suggestion about creating an invitation.
|
||||
|
||||
7.34.02
|
||||
|
||||
Updated GAM to prevent errors like the following:
|
||||
```
|
||||
ERROR: Unable to find the server at oauth2.googleapis.com
|
||||
ERROR: Unable to find the server at gmail.googleapis.com
|
||||
```
|
||||
|
||||
If you experience any unexpected errors, post a message to:
|
||||
* The GAM Discussion Forum (google-apps-manager@googlegroups.com)
|
||||
* The GAM Public Chat Room (https://chat.google.com/app/chat/AAAA4BULhWo)
|
||||
|
||||
7.34.01
|
||||
|
||||
Updated `gam create|update adminrole` to handle the following errors:
|
||||
```
|
||||
ERROR: 400: invalid - Invalid Role privileges
|
||||
ERROR: 400: required - Required parameter: [resource.privileges[n].service_id]
|
||||
```
|
||||
|
||||
7.34.00
|
||||
|
||||
Added variable `csv_output_header_required` to `gam.cfg` that is a comma separated list of `<Strings>`
|
||||
that are required to be in the list of column headers in the CSV file written by a gam print command.
|
||||
This will typically be used to specify headers that are required in subsequent commands that process
|
||||
the CSV file even if the API didn't return any data for those columns.
|
||||
|
||||
Updated the following commands to not require the `Directory API - Domains` scope
|
||||
unless the `internal` or `external` options are used to request the member category.
|
||||
```
|
||||
gam info|print groups
|
||||
gam print|show group-members
|
||||
gam info|print cigroups
|
||||
gam print|show cigroup-members
|
||||
gam <UserTypeEntity> print|show filesharecounts
|
||||
```
|
||||
|
||||
7.33.03
|
||||
|
||||
Fixed bug in `gam [<UserTypeEntity>] sendemail ... from <EmailAddress> replyto <EmailAddress>`
|
||||
where an `<EmailAddress>` of the form `Text <user@domain.com>` had the `Text` removed.
|
||||
|
||||
7.33.02
|
||||
|
||||
Added `hideinvitationssetting` to `<UserCalendarSettingsField>` used by
|
||||
`gam <UserTypeEntity> print|show calsettings`.
|
||||
|
||||
7.33.01
|
||||
|
||||
Added option `shownopolicy` to `gam print chromepolicies` that will display output like the following
|
||||
if no policies apply to the selected OU or group.
|
||||
```
|
||||
gam print chromepolicies ou /Test appid chrome:emidddocikgklceeeifefomdnbkldhng namespace chrome.users.apps shownopolicy
|
||||
Getting all Chrome Policies that match query (chrome.users.apps.*) for /Test
|
||||
Got 0 Chrome Policies that matched query (chrome.users.apps.*) for /Test...
|
||||
name,orgUnitPath,parentOrgUnitPath,direct,appId
|
||||
noPolicy,/Test,/,False,chrome:emidddocikgklceeeifefomdnbkldhng
|
||||
```
|
||||
|
||||
7.33.00
|
||||
|
||||
Added variable `developer_preview_apis` to `gam.cfg` that is a comma separated list of APIs requiring a Developer Preview key.
|
||||
Currently, `chat` is the only API that requires a Developer Preview key; it is required for the User Sections commands.
|
||||
* See: https://github.com/GAM-team/GAM/wiki/Users-Chat#introduction
|
||||
* See: https://github.com/GAM-team/GAM/wiki/Users-Chat#manage-chat-user-sections
|
||||
|
||||
7.32.07
|
||||
|
||||
Added option `includepermissionsforview published` to `gam <UserTypeEntity> print filelist` and
|
||||
`gam <UserTypeEntity> show fileinfo`. From the Drive API documentation:
|
||||
```
|
||||
Specifies which additional view's permissions to include in the response. Only published is supported.
|
||||
```
|
||||
|
||||
7.32.06
|
||||
|
||||
Added options to `gam <UserTypeEntity> copy drivefile ... copysubfiles` to limit copying
|
||||
to files whose `modifiedTime` meets specified requirements.
|
||||
* `start|starttime <Date>|<Time>` - If specified, `modifiedTime` must be >= the value
|
||||
* `end|endtime <Date>|<Time>` - If specified, `modifiedTime` must be <= the value
|
||||
* `range <Date>|<Time> <Date>|<Time>` - first value <= `modifiedTime` <= second value
|
||||
|
||||
7.32.05
|
||||
|
||||
Fixed bug in `gam <UserTypeEntity> print messages|threads ... headers <SMTPHeaderList>` where
|
||||
headers other than those specified in `<SMTPHeaderList>` were displayed.
|
||||
|
||||
Updated `gam info users <UserTypeEntity>` to display the following data when the Licensing API
|
||||
does not return data due to quota limits. Previously, no License data was displayed and
|
||||
there was no way to know if it was omitted due to API quota limits vs the user has no license?
|
||||
```
|
||||
Licenses: (1)
|
||||
Not available/incomplete
|
||||
```
|
||||
If a user has no licenses, this will be displayed.
|
||||
```
|
||||
Licenses: (0)
|
||||
```
|
||||
|
||||
You should use `license_skus = <SKUIDList>` in `gam.cfg` to list all of the licensing SKUs
|
||||
used in your workspace. Without this list, GAM has to make 70+ API calls to get the licenses
|
||||
for a user; this can cause quota limit errors.
|
||||
|
||||
7.32.04
|
||||
|
||||
Support for student groups in Google Classroom no longer requires Developer Preview membership.
|
||||
|
||||
Upgraded to OpenSSL 3.6.1.
|
||||
|
||||
7.32.03
|
||||
|
||||
Added option `template` as an additional formating option for `gam <UserTypeEntity> show signature`
|
||||
that displays just the HTML data; this simplifies capturing the data for use as input to GAM.
|
||||
```
|
||||
$ gam redirect stdout ./SigTemplate.html user user@domain.com show signature template
|
||||
$ more SigTemplate.html
|
||||
<div dir="ltr"><div dir="ltr"><div dir="ltr">
|
||||
<p style="margin:0px;font-size-adjust:none;font-stretch:normal;font-size:12px;line-height:normal;font-family:Monaco;color:rgb(0,0,0)">
|
||||
<span style="background-color:rgb(82,208,206)">{RT}Email: {Email}{/RT}</span></p>
|
||||
<p style="margin:0px;font-size-adjust:none;font-stretch:normal;font-size:12px;line-height:normal;font-family:Monaco;color:rgb(0,0,0)">
|
||||
<span style="background-color:rgb(82,208,206)">{RT}Phone: {Phone}{/RT}</span></p>
|
||||
<p style="margin:0px;font-size-adjust:none;font-stretch:normal;font-size:12px;line-height:normal;font-family:Monaco;color:rgb(0,0,0)">
|
||||
<span style="background-color:rgb(82,208,206)">{RT}Mobile: {Mobile}{/RT}</span></p>
|
||||
</div><br></div>\n</div>
|
||||
|
||||
```
|
||||
|
||||
7.32.02
|
||||
|
||||
Added variable `oauth2_txt_lock_mode` to `gam.cfg`, the default is 644 and valid values are: 644, 664, 666.
|
||||
This value is used to set the file permissions on the `oauth2.txt.lock` file. In very special cases where
|
||||
daemon processes, e.g. Apache/httpd, are running GAM, the value 666 may have to be used.
|
||||
|
||||
7.32.01
|
||||
|
||||
Added option `(addcsvdata <FieldName> <String>)*` to `gam <CrOSTypeEntity> issuecommand command <CrOSCommand> csv`
|
||||
and `gam <CrOSTypeEntity> getcommand commandid <CommandID> csv` that adds additional columns of data to the CSV file output.
|
||||
* See: https://github.com/GAM-team/GAM/wiki/ChromeOS-Devices#bulk-action-example
|
||||
|
||||
7.32.00
|
||||
|
||||
Added option `verifyallowexternal` to `gam print cigroup-members|group-members` that causes
|
||||
GAM to only display external members in groups with `allowExternalMembers=False'.
|
||||
This option can be used to help verify that internal-only groups don't have external members.
|
||||
|
||||
Updated option `internaldomains` for the following commands:
|
||||
```
|
||||
gam info|print groups
|
||||
gam print|show group-members
|
||||
gam info|print cigroups
|
||||
gam print|show cigroup-members
|
||||
gam <UserTypeEntity> print|show filesharecounts
|
||||
```
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Added option `csv` to `gam <CrOSTypeEntity> issuecommand command <CrOSCommand>`
|
||||
and `gam <CrOSTypeEntity> getcommand commandid <CommandID>` so that command details are displayed in CSV format.
|
||||
This can be used to log commands issued to devices and then monitor the results.
|
||||
|
||||
Added option `filemimetype category <MimeTypeNameList>` to `gam <UserTypeEntity> copy drivefile` to support
|
||||
copying of files based on their MimeType category.
|
||||
|
||||
Added option `attendeeslist` to `gam calendars <CalendarEntity> print events` and `gam <UserTypeEntity> print events`
|
||||
that causes GAM to display the attendee email addresses in a single column `attendeesList`; no attendee details
|
||||
are displayed. The email addresses are separated by `csv_output_field_delimiter` from `gam.cfg`.
|
||||
|
||||
Fixed bug in `gam sendemail ... replyto <EmailAddress>` that caused a message delivery error if
|
||||
`<EmailAddress>` did not include a domain name.
|
||||
|
||||
Added support for users's chat sections.
|
||||
* See: https://github.com/GAM-team/GAM/wiki/Users-Chat#manage-chat-users-sections
|
||||
* This is in Deveoper Preview; you must have a `developer_preview_api_key` in `gam.cfg` to use these commands.
|
||||
|
||||
7.31.06
|
||||
|
||||
Added option `batchsize <Integer>` to `gam calendar <CalendarEntity> delete|purge events` and
|
||||
`gam <UserTypeEntity> delete|purge events <UserCalendarEntity>` that causes GAM to delete events
|
||||
with batch API calls rather than with individual API calls.
|
||||
|
||||
7.31.05
|
||||
|
||||
Added option `variables <RESearchPattern>` to `gam select section <SectionName> verify` and `gam config verify`
|
||||
that causes GAM to only display variables with names selected by `<RESearchPattern>`.
|
||||
```
|
||||
gam select School verify variables "^(customer|domain)"
|
||||
Section: School
|
||||
customer_id = C03abc123
|
||||
domain = school.edu
|
||||
|
||||
gam config verify variables 'dir'
|
||||
Section: DEFAULT
|
||||
cache_dir = ~/GamConfig/gamcache ; /Users/gamteam/GamConfig/gamcache
|
||||
config_dir = ~/GamConfig ; /Users/gamteam/GamConfig
|
||||
drive_dir = ~/GamWork ; /Users/gamteam/GamWork
|
||||
gmail_cse_incert_dir = ~/GmailCSE/Certs ; /Users/gamteam/GmailCSE/Certs
|
||||
gmail_cse_inkey_dir = ~/GmailCSE/Keys ; /Users/gamteam/GmailCSE/Keys
|
||||
input_dir = .
|
||||
```
|
||||
|
||||
7.31.04
|
||||
|
||||
Fixed bug in `gam report admin|chrome` that caused to events to not be displayed.
|
||||
|
||||
Updated `gam <UserTypeEntity> print|show messages|threads ... query <QueryGmail>` to display the query.
|
||||
|
||||
7.31.03
|
||||
|
||||
Due to the following Calendar API update, the `gam <UserTypeEntity> transfer calendars` command has been removed.
|
||||
* See: https://developers.google.com/workspace/calendar/release-notes#October_27_2025
|
||||
Data ownership can be transferred in the Google Calendar UI.
|
||||
|
||||
7.31.02
|
||||
|
||||
Added the following options to `gam <UserTypeEntity> copy drivefile`
|
||||
to limit copying to those files owned by selected users.
|
||||
* `copysubfilesownedby users <EmailAddressList>` - Only files owned by users in `<EmailAddressList>` are copied.
|
||||
* `copysubfilesownedby notusers <EmailAddressList>` - Only files not owned by users in `<EmailAddressList>` are copied.
|
||||
* `copysubfilesownedby regex <REMatchPattern>` - Only files owned by users whose email addresses match `<REMatchPattern>` are copied.
|
||||
* `copysubfilesownedby notregex <REMatchPattern>` - Only files owned by users whose email addresses do not match `<REMatchPattern>` are copied.
|
||||
|
||||
7.31.01
|
||||
|
||||
Code cleanup for `addcsvdata <FieldName> <String>`.
|
||||
|
||||
7.31.00
|
||||
|
||||
Fixed bug in `gam report chrome (user <UserItem>)|(select <UserTypeEntity>)` where no activities were returned.
|
||||
`report chrome` does not use the parameter `userKey=<EmailAddress>` as do other applications but requires
|
||||
parameter `filter DEVICE_USER==<EmailAddress>`.
|
||||
|
||||
Updated `gam report admin (user <UserItem>)|(select <UserTypeEntity>)` to use parameter `filter USER_EMAIL==<EmailAddress>`
|
||||
to display activiities affecting the user `<EmailAddress>`. Use option `userisactor` to use the parameter `userKey=<EmailAddress>`
|
||||
that displays activities where user `<EmailAddress>` executed the command that generated the activity.
|
||||
|
||||
Fixed bug in `gam print cros|filelist|users ... (addcsvdata <FieldName> <String>)+ formatjson` where the `addcsvdata` columns
|
||||
were not displayed but the additional field values were included in the JSON data. Now, the `addcsvdata` columns
|
||||
are displayed but the additional field values are only included in the JSON data when option `includdecsvdatainjson` is specified.
|
||||
|
||||
Added option `addcsvdata <FieldName> <String>` to `gam <UserTypeEntity> print cigroups|groups`
|
||||
that adds additional columns of data to the CSV file output.
|
||||
|
||||
Added option `addcsvdata <FieldName> <String>` to `gam <UserTypeEntity> print cigroupmembere|group-members`
|
||||
that adds additional columns of data to the CSV file output.
|
||||
|
||||
7.30.05
|
||||
|
||||
Added option `gmaileventtypes <NumberRangeList>` to `gam report gmail` that can be used to limit the event types displayed.
|
||||
```
|
||||
<NumberRange> ::= <Number>|(<Number>/<Number>)
|
||||
<NumberRangeList> ::= "<NumberRange>(,<NumberRange>)*"
|
||||
|
||||
gam report gmail user user@domain.com gmaileventtypes 1,10/11
|
||||
```
|
||||
* See: https://developers.google.com/workspace/admin/reports/v1/appendix/activity/gmail
|
||||
|
||||
Updated sorting of column headers in `gam report <ActivityApplicationName>`.
|
||||
|
||||
7.30.04
|
||||
|
||||
Updated `gam report gmail` to avoid the following error when incomplete start/end time information is provided.
|
||||
```
|
||||
ERROR: Invalid request: Start time and end time should both be provided, and the scan duration should not be greater than 30 days.
|
||||
```
|
||||
* No time information provided - GAM sets `range -30d today`
|
||||
* Only `start <Time>` provided - GAM sets `end <Time>+30d`
|
||||
* Only `end <Time>` provided - GAM sets `start <Time>-30d`
|
||||
|
||||
7.30.03
|
||||
|
||||
Updated `gam report <ActivityApplicationName>` to reflect the changes described here:
|
||||
* See: https://workspaceupdates.googleblog.com/2025/12/google-workspace-audit-log-api.html
|
||||
|
||||
Added option `resourcedetailsfilter <String>` to `gam report <ActivityApplicationName>` described here:
|
||||
* See: https://developers.google.com/workspace/admin/reports/reference/rest/v1/activities/list#query-parameters
|
||||
|
||||
For `gam <UserTypeEntity> print <Objects>`, expanded the list of `<Objects>` covered by `gam.cfg csv_output_users_audit = True`.
|
||||
|
||||
7.30.02
|
||||
|
||||
Added option `conferencedata meet <MeetID>` to `<EventAttribute>` that allows specifying
|
||||
|
||||
2671
src/gam/__init__.py
2671
src/gam/__init__.py
File diff suppressed because it is too large
Load Diff
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright (C) 2025 Ross Scroggs All Rights Reserved.
|
||||
# Copyright (C) 2026 Ross Scroggs All Rights Reserved.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
#
|
||||
@@ -32,6 +32,7 @@ CHAT_EVENTS = 'chatevents'
|
||||
CHAT_MEMBERSHIPS = 'chatmemberships'
|
||||
CHAT_MEMBERSHIPS_ADMIN = 'chatmembershipsadmin'
|
||||
CHAT_MESSAGES = 'chatmessages'
|
||||
CHAT_SECTIONS = 'chatsections'
|
||||
CHAT_SPACES = 'chatspaces'
|
||||
CHAT_SPACES_ADMIN = 'chatspacesadmin'
|
||||
CHAT_SPACES_DELETE = 'chatspacesdelete'
|
||||
@@ -229,6 +230,7 @@ _INFO = {
|
||||
CHAT_MEMBERSHIPS: {'name': 'Chat API - Memberships', 'version': 'v1', 'v2discovery': True, 'mappedAPI': CHAT},
|
||||
CHAT_MEMBERSHIPS_ADMIN: {'name': 'Chat API - Memberships Admin', 'version': 'v1', 'v2discovery': True, 'mappedAPI': CHAT},
|
||||
CHAT_MESSAGES: {'name': 'Chat API - Messages', 'version': 'v1', 'v2discovery': True, 'mappedAPI': CHAT},
|
||||
CHAT_SECTIONS: {'name': 'Chat API - User Sections', 'version': 'v1', 'v2discovery': True, 'mappedAPI': CHAT},
|
||||
CHAT_SPACES: {'name': 'Chat API - Spaces', 'version': 'v1', 'v2discovery': True, 'mappedAPI': CHAT},
|
||||
CHAT_SPACES_ADMIN: {'name': 'Chat API - Spaces Admin', 'version': 'v1', 'v2discovery': True, 'mappedAPI': CHAT},
|
||||
CHAT_SPACES_DELETE: {'name': 'Chat API - Spaces Delete', 'version': 'v1', 'v2discovery': True, 'mappedAPI': CHAT},
|
||||
@@ -594,6 +596,11 @@ _SVCACCT_SCOPES = [
|
||||
'api': CHAT_MESSAGES,
|
||||
'subscopes': READONLY,
|
||||
'scope': 'https://www.googleapis.com/auth/chat.messages'},
|
||||
{'name': 'Chat API - User Sections',
|
||||
'api': CHAT_SECTIONS,
|
||||
'offByDefault': True,
|
||||
'subscopes': READONLY,
|
||||
'scope': 'https://www.googleapis.com/auth/chat.users.sections'},
|
||||
{'name': 'Chat API - Spaces',
|
||||
'api': CHAT_SPACES,
|
||||
'subscopes': READONLY,
|
||||
@@ -642,6 +649,16 @@ _SVCACCT_SCOPES = [
|
||||
'api': CLOUDIDENTITY_DEVICES,
|
||||
'subscopes': READONLY,
|
||||
'scope': 'https://www.googleapis.com/auth/cloud-identity.devices'},
|
||||
# {'name': 'Cloud Identity API - Policy',
|
||||
# 'api': CLOUDIDENTITY_POLICY,
|
||||
# 'subscopes': READONLY,
|
||||
# 'roByDefault': True,
|
||||
# 'scope': 'https://www.googleapis.com/auth/cloud-identity.policies'},
|
||||
# {'name': 'Cloud Identity API - Policy Beta',
|
||||
# 'api': CLOUDIDENTITY_POLICY_BETA,
|
||||
# 'subscopes': [],
|
||||
# 'offByDefault': True,
|
||||
# 'scope': 'https://www.googleapis.com/auth/cloud-identity.policies'},
|
||||
# {'name': 'Cloud Identity User Invitations API',
|
||||
# 'api': CLOUDIDENTITY_USERINVITATIONS,
|
||||
# 'subscopes': READONLY,
|
||||
@@ -805,6 +822,12 @@ def getVersion(api):
|
||||
api = _INFO[api].get('mappedAPI', api)
|
||||
return (api, version, v2discovery)
|
||||
|
||||
def getAPIsList():
|
||||
apisList = set()
|
||||
for api, value in _INFO.items():
|
||||
apisList.add(value.get('mappedAPI', api))
|
||||
return apisList
|
||||
|
||||
def getClientScopesSet(api):
|
||||
return {scope['scope'] for scope in _CLIENT_SCOPES if scope['api'] == api}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright (C) 2025 Ross Scroggs All Rights Reserved.
|
||||
# Copyright (C) 2026 Ross Scroggs All Rights Reserved.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
#
|
||||
@@ -123,6 +123,8 @@ CSV_OUTPUT_HEADER_DROP_FILTER = 'csv_output_header_drop_filter'
|
||||
CSV_OUTPUT_HEADER_FORCE = 'csv_output_header_force'
|
||||
# Orde output column headers
|
||||
CSV_OUTPUT_HEADER_ORDER = 'csv_output_header_order'
|
||||
# Required output column headers
|
||||
CSV_OUTPUT_HEADER_REQUIRED = 'csv_output_header_required'
|
||||
# Line terminator in CSV output file
|
||||
CSV_OUTPUT_LINE_TERMINATOR = 'csv_output_line_terminator'
|
||||
# Quote character in CSV output file
|
||||
@@ -151,6 +153,8 @@ CUSTOMER_ID = 'customer_id'
|
||||
DEBUG_LEVEL = 'debug_level'
|
||||
# redact sensitive credentials from debug output
|
||||
DEBUG_REDACTION = 'debug_redaction'
|
||||
# Developer Preview APIs
|
||||
DEVELOPER_PREVIEW_APIS = 'developer_preview_apis'
|
||||
# Developer Preview API Key
|
||||
DEVELOPER_PREVIEW_API_KEY = 'developer_preview_api_key'
|
||||
# When retrieving lists of ChromeOS devices from API, how many should be retrieved in each chunk
|
||||
@@ -218,6 +222,8 @@ NUM_TBATCH_THREADS = 'num_tbatch_threads'
|
||||
NUM_THREADS = 'num_threads'
|
||||
# Path to oauth2.txt
|
||||
OAUTH2_TXT = 'oauth2_txt'
|
||||
# File permissions for oauth2.txt.lock
|
||||
OAUTH2_TXT_LOCK_MODE = 'oauth2_txt_lock_mode'
|
||||
# Path to oauth2service.json
|
||||
OAUTH2SERVICE_JSON = 'oauth2service_json'
|
||||
# Output date format, empty defalts to ISOFormat
|
||||
@@ -325,6 +331,7 @@ CSV_INPUT_ROW_FILTER_ITEMS = {CSV_INPUT_ROW_FILTER, CSV_INPUT_ROW_FILTER_MODE,
|
||||
|
||||
CSV_OUTPUT_ROW_FILTER_ITEMS = {CSV_OUTPUT_HEADER_FILTER, CSV_OUTPUT_HEADER_DROP_FILTER,
|
||||
CSV_OUTPUT_HEADER_FORCE, CSV_OUTPUT_HEADER_ORDER,
|
||||
CSV_OUTPUT_HEADER_REQUIRED,
|
||||
CSV_OUTPUT_ROW_FILTER, CSV_OUTPUT_ROW_FILTER_MODE,
|
||||
CSV_OUTPUT_ROW_DROP_FILTER, CSV_OUTPUT_ROW_DROP_FILTER_MODE,
|
||||
CSV_OUTPUT_ROW_LIMIT}
|
||||
@@ -369,6 +376,7 @@ Defaults = {
|
||||
CSV_OUTPUT_HEADER_DROP_FILTER: '',
|
||||
CSV_OUTPUT_HEADER_FORCE: '',
|
||||
CSV_OUTPUT_HEADER_ORDER: '',
|
||||
CSV_OUTPUT_HEADER_REQUIRED: '',
|
||||
CSV_OUTPUT_LINE_TERMINATOR: 'lf',
|
||||
CSV_OUTPUT_QUOTE_CHAR: '\'"\'',
|
||||
CSV_OUTPUT_ROW_FILTER: '',
|
||||
@@ -383,6 +391,7 @@ Defaults = {
|
||||
CUSTOMER_ID: MY_CUSTOMER,
|
||||
DEBUG_LEVEL: '0',
|
||||
DEBUG_REDACTION: TRUE,
|
||||
DEVELOPER_PREVIEW_APIS: '',
|
||||
DEVELOPER_PREVIEW_API_KEY: '',
|
||||
DEVICE_MAX_RESULTS: '200',
|
||||
DOMAIN: '',
|
||||
@@ -416,6 +425,7 @@ Defaults = {
|
||||
NUM_TBATCH_THREADS: '2',
|
||||
NUM_THREADS: '5',
|
||||
OAUTH2_TXT: FN_OAUTH2_TXT,
|
||||
OAUTH2_TXT_LOCK_MODE: '644',
|
||||
OAUTH2SERVICE_JSON: FN_OAUTH2SERVICE_JSON,
|
||||
OUTPUT_DATEFORMAT: '',
|
||||
OUTPUT_TIMEFORMAT: '',
|
||||
@@ -481,7 +491,7 @@ TYPE_EMAIL_OPTIONAL = 'emao'
|
||||
TYPE_FILE = 'file'
|
||||
TYPE_FLOAT = 'floa'
|
||||
TYPE_HEADERFILTER = 'heaf'
|
||||
TYPE_HEADERFORCE = 'hefo'
|
||||
TYPE_HEADERFORCEREQUIRED = 'hefr'
|
||||
TYPE_HEADERORDER = 'heor'
|
||||
TYPE_INTEGER = 'inte'
|
||||
TYPE_LANGUAGE = 'lang'
|
||||
@@ -538,8 +548,9 @@ VAR_INFO = {
|
||||
CSV_OUTPUT_FIELD_DELIMITER: {VAR_TYPE: TYPE_CHARACTER},
|
||||
CSV_OUTPUT_HEADER_FILTER: {VAR_TYPE: TYPE_HEADERFILTER},
|
||||
CSV_OUTPUT_HEADER_DROP_FILTER: {VAR_TYPE: TYPE_HEADERFILTER},
|
||||
CSV_OUTPUT_HEADER_FORCE: {VAR_TYPE: TYPE_HEADERFORCE},
|
||||
CSV_OUTPUT_HEADER_FORCE: {VAR_TYPE: TYPE_HEADERFORCEREQUIRED},
|
||||
CSV_OUTPUT_HEADER_ORDER: {VAR_TYPE: TYPE_HEADERORDER},
|
||||
CSV_OUTPUT_HEADER_REQUIRED: {VAR_TYPE: TYPE_HEADERFORCEREQUIRED},
|
||||
CSV_OUTPUT_LINE_TERMINATOR: {VAR_TYPE: TYPE_CHOICE, VAR_CHOICES: {'cr': '\r', 'lf': '\n', 'crlf': '\r\n'}},
|
||||
CSV_OUTPUT_QUOTE_CHAR: {VAR_TYPE: TYPE_CHARACTER},
|
||||
CSV_OUTPUT_ROW_FILTER: {VAR_TYPE: TYPE_ROWFILTER},
|
||||
@@ -554,6 +565,7 @@ VAR_INFO = {
|
||||
CUSTOMER_ID: {VAR_TYPE: TYPE_STRING, VAR_ENVVAR: 'CUSTOMER_ID', VAR_LIMITS: (0, None)},
|
||||
DEBUG_LEVEL: {VAR_TYPE: TYPE_INTEGER, VAR_SIGFILE: 'debug.gam', VAR_LIMITS: (0, None), VAR_SFFT: ('0', '4')},
|
||||
DEBUG_REDACTION: {VAR_TYPE: TYPE_BOOLEAN},
|
||||
DEVELOPER_PREVIEW_APIS: {VAR_TYPE: TYPE_STRING, VAR_LIMITS: (0, None)},
|
||||
DEVELOPER_PREVIEW_API_KEY: {VAR_TYPE: TYPE_STRING, VAR_LIMITS: (0, None)},
|
||||
DEVICE_MAX_RESULTS: {VAR_TYPE: TYPE_INTEGER, VAR_LIMITS: (1, 200)},
|
||||
DOMAIN: {VAR_TYPE: TYPE_STRING, VAR_ENVVAR: 'GA_DOMAIN', VAR_LIMITS: (0, None)},
|
||||
@@ -587,6 +599,7 @@ VAR_INFO = {
|
||||
NUM_TBATCH_THREADS: {VAR_TYPE: TYPE_INTEGER, VAR_LIMITS: (1, 1000)},
|
||||
NUM_THREADS: {VAR_TYPE: TYPE_INTEGER, VAR_ENVVAR: 'GAM_THREADS', VAR_LIMITS: (1, 1000)},
|
||||
OAUTH2_TXT: {VAR_TYPE: TYPE_FILE, VAR_ENVVAR: 'OAUTHFILE', VAR_ACCESS: os.R_OK | os.W_OK},
|
||||
OAUTH2_TXT_LOCK_MODE: {VAR_TYPE: TYPE_CHOICE, VAR_CHOICES: {'644': 0o644, '664': 0o664, '666': 0o666}},
|
||||
OAUTH2SERVICE_JSON: {VAR_TYPE: TYPE_FILE, VAR_ENVVAR: 'OAUTHSERVICEFILE', VAR_ACCESS: os.R_OK | os.W_OK},
|
||||
OUTPUT_DATEFORMAT: {VAR_TYPE: TYPE_STRING, VAR_LIMITS: (0, None)},
|
||||
OUTPUT_TIMEFORMAT: {VAR_TYPE: TYPE_STRING, VAR_LIMITS: (0, None)},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright (C) 2025 Ross Scroggs All Rights Reserved.
|
||||
# Copyright (C) 2026 Ross Scroggs All Rights Reserved.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
#
|
||||
@@ -751,6 +751,10 @@ class GamCLArgs():
|
||||
ARG_CHATMEMBERS = 'chatmembers'
|
||||
ARG_CHATMESSAGE = 'chatmessage'
|
||||
ARG_CHATMESSAGES = 'chatmessages'
|
||||
ARG_CHATSECTION = 'chatsection'
|
||||
ARG_CHATSECTIONS = 'chatsections'
|
||||
ARG_CHATSECTIONITEM = 'chatsectionitem'
|
||||
ARG_CHATSECTIONITEMS = 'chatsectionitems'
|
||||
ARG_CHATSPACE = 'chatspace'
|
||||
ARG_CHATSPACES = 'chatspaces'
|
||||
ARG_CHATSPACEDM = 'chatspacedm'
|
||||
@@ -924,6 +928,8 @@ class GamCLArgs():
|
||||
ARG_GUARDIANINVITE = 'guardianinvite'
|
||||
ARG_GUARDIANINVITATION = 'guardianinvitation'
|
||||
ARG_GUARDIANINVITATIONS = 'guardianinvitations'
|
||||
ARG_GUESTUSER = 'guestuser'
|
||||
ARG_GUESTUSERS = 'guestusers'
|
||||
ARG_HOLD = 'hold'
|
||||
ARG_HOLDS = 'holds'
|
||||
ARG_IMAP = 'imap'
|
||||
@@ -1157,6 +1163,7 @@ class GamCLArgs():
|
||||
OB_CHAT_MEMBER = 'ChatMember'
|
||||
OB_CHAT_MESSAGE = 'ChatMessage'
|
||||
OB_CHAT_MESSAGE_ID = 'ChatMessageID'
|
||||
OB_CHAT_SECTION = 'ChatSection'
|
||||
OB_CHAT_SPACE = 'ChatSpace'
|
||||
OB_CHAT_SPACE_LIST = 'ChatSpaceList'
|
||||
OB_CHAT_THREAD = 'ChatThread'
|
||||
@@ -1286,6 +1293,7 @@ class GamCLArgs():
|
||||
OB_MOBILE_ENTITY = 'MobileEntity'
|
||||
OB_NETWORK_ID = 'networkID'
|
||||
OB_NAME = 'Name'
|
||||
OB_NUMBER_RANGE_LIST = 'NumberRangeList'
|
||||
OB_ORGANIZER_TYPE_LIST = 'OrganizerTypeList'
|
||||
OB_ORGUNIT_ENTITY = 'OrgUnitEntity'
|
||||
OB_ORGUNIT_ITEM = 'OrgUnitItem'
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright (C) 2025 Ross Scroggs All Rights Reserved.
|
||||
# Copyright (C) 2026 Ross Scroggs All Rights Reserved.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
#
|
||||
@@ -97,6 +97,8 @@ class GamEntity():
|
||||
CHAT_MESSAGE = 'chms'
|
||||
CHAT_MESSAGE_ID = 'chmi'
|
||||
CHAT_OWNER_USER = 'chou'
|
||||
CHAT_SECTION = 'chse'
|
||||
CHAT_SECTION_ITEM = 'chsi'
|
||||
CHAT_SPACE = 'chsp'
|
||||
CHAT_THREAD = 'chth'
|
||||
CHILD_ORGANIZATIONAL_UNIT = 'corg'
|
||||
@@ -251,6 +253,7 @@ class GamEntity():
|
||||
GUARDIAN = 'guar'
|
||||
GUARDIAN_INVITATION = 'gari'
|
||||
GUARDIAN_AND_INVITATION = 'gani'
|
||||
GUEST_USER = 'gstu'
|
||||
IAM_POLICY = 'iamp'
|
||||
IMAP_ENABLED = 'imap'
|
||||
INBOUND_SSO_ASSIGNMENT = 'insa'
|
||||
@@ -356,7 +359,7 @@ class GamEntity():
|
||||
SNIPPETS_ENABLED = 'snip'
|
||||
SSO_KEY = 'ssok'
|
||||
SSO_SETTINGS = 'ssos'
|
||||
SOURCE_USER = 'src'
|
||||
SOURCE_USER = 'srcu'
|
||||
SPREADSHEET = 'sprd'
|
||||
SPREADSHEET_RANGE = 'ssrn'
|
||||
START_TIME = 'strt'
|
||||
@@ -465,6 +468,8 @@ class GamEntity():
|
||||
CHAT_MEMBER_GROUP: ['Chat Group Members', 'Chat Group Member'],
|
||||
CHAT_MEMBER_USER: ['Chat User Members', 'Chat User Member'],
|
||||
CHAT_OWNER_USER: ['Chat User Owners', 'Chat User Owner'],
|
||||
CHAT_SECTION: ['Chat User Sections', 'Chat User Section'],
|
||||
CHAT_SECTION_ITEM: ['Chat User Section Items', 'Chat User Section Item'],
|
||||
CHAT_SPACE: ['Chat Spaces', 'Chat Space'],
|
||||
CHAT_THREAD: ['Chat Threads', 'Chat Thread'],
|
||||
CHILD_ORGANIZATIONAL_UNIT: ['Child Organizational Units', 'Child Organizational Unit'],
|
||||
@@ -616,6 +621,7 @@ class GamEntity():
|
||||
GROUP_MEMBERSHIP_TREE: ['Group Membership Trees', 'Group Membership Tree'],
|
||||
GROUP_SETTINGS: ['Group Settings', 'Group Settings'],
|
||||
GROUP_TREE: ['Group Trees', 'Group Tree'],
|
||||
GUEST_USER: ['Guest Users', 'Guest User'],
|
||||
GUARDIAN: ['Guardians', 'Guardian'],
|
||||
GUARDIAN_INVITATION: ['Guardian Invitations', 'Guardian Invitation'],
|
||||
GUARDIAN_AND_INVITATION: ['Guardians and Invitations', 'Guardian and Invitation'],
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright (C) 2025 Ross Scroggs All Rights Reserved.
|
||||
# Copyright (C) 2026 Ross Scroggs All Rights Reserved.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
#
|
||||
@@ -42,6 +42,7 @@ CANNOT_DELETE_PERMISSION = 'cannotDeletePermission'
|
||||
CANNOT_DELETE_PRIMARY_CALENDAR = 'cannotDeletePrimaryCalendar'
|
||||
CANNOT_DELETE_PRIMARY_SENDAS = 'cannotDeletePrimarySendAs'
|
||||
CANNOT_DELETE_RESOURCE_WITH_CHILDREN = 'cannotDeleteResourceWithChildren'
|
||||
CANNOT_MODIFY_ACL_OF_CALENDAR_OWNER = 'cannotModifyAclOfCalendarOwner'
|
||||
CANNOT_MODIFY_INHERITED_PERMISSION = 'cannotModifyInheritedPermission'
|
||||
CANNOT_MODIFY_INHERITED_TEAMDRIVE_PERMISSION = 'cannotModifyInheritedTeamDrivePermission'
|
||||
CANNOT_MODIFY_RESTRICTED_LABEL = 'cannotModifyRestrictedLabel'
|
||||
@@ -55,6 +56,7 @@ CANNOT_SHARE_GROUPS_WITHLINK = 'cannotShareGroupsWithLink'
|
||||
CANNOT_SHARE_USERS_WITHLINK = 'cannotShareUsersWithLink'
|
||||
CANNOT_SHARE_TEAMDRIVE_TOPFOLDER_WITH_ANYONEORDOMAINS = 'cannotShareTeamDriveTopFolderWithAnyoneOrDomains'
|
||||
CANNOT_SHARE_TEAMDRIVE_WITH_NONGOOGLE_ACCOUNTS = 'cannotShareTeamDriveWithNonGoogleAccounts'
|
||||
CANNOT_UNSUBSCRIBE_FROM_OWNED_CALENDAR = 'cannotUnsubscribeFromOwnedCalendar'
|
||||
CANNOT_UPDATE_PERMISSION = 'cannotUpdatePermission'
|
||||
CONDITION_NOT_MET = 'conditionNotMet'
|
||||
CONFLICT = 'conflict'
|
||||
@@ -179,6 +181,7 @@ TEAMDRIVES_SHARING_RESTRICTION_NOT_ALLOWED = 'teamDrivesSharingRestrictionNotAll
|
||||
TEAMDRIVES_SHORTCUT_FILE_NOT_SUPPORTED = 'teamDrivesShortcutFileNotSupported'
|
||||
TIME_RANGE_EMPTY = 'timeRangeEmpty'
|
||||
TRANSIENT_ERROR = 'transientError'
|
||||
UNIMPLEMENTED_ERROR = 'unimplementedError'
|
||||
UNKNOWN_ERROR = 'unknownError'
|
||||
UNSUPPORTED_LANGUAGE_CODE = 'unsupportedLanguageCode'
|
||||
UNSUPPORTED_SUPERVISED_ACCOUNT = 'unsupportedSupervisedAccount'
|
||||
@@ -195,7 +198,7 @@ ACTIVITY_THROW_REASONS = [SERVICE_NOT_AVAILABLE, BAD_REQUEST]
|
||||
ALERT_THROW_REASONS = [SERVICE_NOT_AVAILABLE, AUTH_ERROR, PERMISSION_DENIED]
|
||||
CALENDAR_THROW_REASONS = [SERVICE_NOT_AVAILABLE, AUTH_ERROR, NOT_A_CALENDAR_USER]
|
||||
CIGROUP_CREATE_THROW_REASONS = [SERVICE_NOT_AVAILABLE, ALREADY_EXISTS, DOMAIN_NOT_FOUND, DOMAIN_CANNOT_USE_APIS, FORBIDDEN, INVALID, INVALID_ARGUMENT, PERMISSION_DENIED, FAILED_PRECONDITION]
|
||||
CIGROUP_GET_THROW_REASONS = [SERVICE_NOT_AVAILABLE, NOT_FOUND, GROUP_NOT_FOUND, DOMAIN_NOT_FOUND, DOMAIN_CANNOT_USE_APIS, FORBIDDEN, BAD_REQUEST, INVALID, SYSTEM_ERROR, PERMISSION_DENIED]
|
||||
CIGROUP_GET_THROW_REASONS = [SERVICE_NOT_AVAILABLE, NOT_FOUND, GROUP_NOT_FOUND, DOMAIN_NOT_FOUND, DOMAIN_CANNOT_USE_APIS, FORBIDDEN, BAD_REQUEST, INVALID, INVALID_ARGUMENT, SYSTEM_ERROR, PERMISSION_DENIED]
|
||||
CIGROUP_LIST_THROW_REASONS = [SERVICE_NOT_AVAILABLE, RESOURCE_NOT_FOUND, DOMAIN_NOT_FOUND, DOMAIN_CANNOT_USE_APIS, FORBIDDEN, BAD_REQUEST, INVALID, INVALID_ARGUMENT, SYSTEM_ERROR, PERMISSION_DENIED]
|
||||
CIGROUP_LIST_USERKEY_THROW_REASONS = CIGROUP_LIST_THROW_REASONS+[INVALID_ARGUMENT]
|
||||
CIGROUP_UPDATE_THROW_REASONS = [SERVICE_NOT_AVAILABLE, NOT_FOUND, GROUP_NOT_FOUND, DOMAIN_NOT_FOUND, DOMAIN_CANNOT_USE_APIS,
|
||||
@@ -405,6 +408,8 @@ class cannotDeletePrimarySendAs(Exception):
|
||||
pass
|
||||
class cannotDeleteResourceWithChildren(Exception):
|
||||
pass
|
||||
class cannotModifyAclOfCalendarOwner(Exception):
|
||||
pass
|
||||
class cannotModifyInheritedPermission(Exception):
|
||||
pass
|
||||
class cannotModifyInheritedTeamDrivePermission(Exception):
|
||||
@@ -431,6 +436,8 @@ class cannotShareTeamDriveTopFolderWithAnyoneOrDomains(Exception):
|
||||
pass
|
||||
class cannotShareTeamDriveWithNonGoogleAccounts(Exception):
|
||||
pass
|
||||
class cannotUnsubscribeFromOwnedCalendar(Exception):
|
||||
pass
|
||||
class cannotUpdatePermission(Exception):
|
||||
pass
|
||||
class conditionNotMet(Exception):
|
||||
@@ -671,6 +678,8 @@ class timeRangeEmpty(Exception):
|
||||
pass
|
||||
class transientError(Exception):
|
||||
pass
|
||||
class unimplementedError(Exception):
|
||||
pass
|
||||
class unknownError(Exception):
|
||||
pass
|
||||
class unsupportedLanguageCode(Exception):
|
||||
@@ -710,6 +719,7 @@ REASON_EXCEPTION_MAP = {
|
||||
CANNOT_DELETE_PRIMARY_CALENDAR: cannotDeletePrimaryCalendar,
|
||||
CANNOT_DELETE_PRIMARY_SENDAS: cannotDeletePrimarySendAs,
|
||||
CANNOT_DELETE_RESOURCE_WITH_CHILDREN: cannotDeleteResourceWithChildren,
|
||||
CANNOT_MODIFY_ACL_OF_CALENDAR_OWNER: cannotModifyAclOfCalendarOwner,
|
||||
CANNOT_MODIFY_INHERITED_PERMISSION: cannotModifyInheritedPermission,
|
||||
CANNOT_MODIFY_INHERITED_TEAMDRIVE_PERMISSION: cannotModifyInheritedTeamDrivePermission,
|
||||
CANNOT_MODIFY_RESTRICTED_LABEL: cannotModifyRestrictedLabel,
|
||||
@@ -723,6 +733,7 @@ REASON_EXCEPTION_MAP = {
|
||||
CANNOT_SHARE_USERS_WITHLINK: cannotShareUsersWithLink,
|
||||
CANNOT_SHARE_TEAMDRIVE_TOPFOLDER_WITH_ANYONEORDOMAINS: cannotShareTeamDriveTopFolderWithAnyoneOrDomains,
|
||||
CANNOT_SHARE_TEAMDRIVE_WITH_NONGOOGLE_ACCOUNTS: cannotShareTeamDriveWithNonGoogleAccounts,
|
||||
CANNOT_UNSUBSCRIBE_FROM_OWNED_CALENDAR: cannotUnsubscribeFromOwnedCalendar,
|
||||
CANNOT_UPDATE_PERMISSION: cannotUpdatePermission,
|
||||
CONDITION_NOT_MET: conditionNotMet,
|
||||
CONFLICT: conflict,
|
||||
@@ -843,6 +854,7 @@ REASON_EXCEPTION_MAP = {
|
||||
TEAMDRIVES_SHORTCUT_FILE_NOT_SUPPORTED: teamDrivesShortcutFileNotSupported,
|
||||
TIME_RANGE_EMPTY: timeRangeEmpty,
|
||||
TRANSIENT_ERROR: transientError,
|
||||
UNIMPLEMENTED_ERROR: unimplementedError,
|
||||
UNKNOWN_ERROR: unknownError,
|
||||
UNSUPPORTED_LANGUAGE_CODE: unsupportedLanguageCode,
|
||||
UNSUPPORTED_SUPERVISED_ACCOUNT: unsupportedSupervisedAccount,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright (C) 2025 Ross Scroggs All Rights Reserved.
|
||||
# Copyright (C) 2026 Ross Scroggs All Rights Reserved.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
#
|
||||
@@ -69,6 +69,8 @@ CSV_OUTPUT_HEADER_FILTER = 'cohf'
|
||||
CSV_OUTPUT_HEADER_FORCE = 'cofh'
|
||||
# Order output column headers
|
||||
CSV_OUTPUT_HEADER_ORDER = 'coho'
|
||||
# Required output column headers
|
||||
CSV_OUTPUT_HEADER_REQUIRED = 'corh'
|
||||
# No escape character in CSV output file
|
||||
CSV_OUTPUT_NO_ESCAPE_CHAR = 'cone'
|
||||
# Quote character in CSV output file
|
||||
@@ -111,6 +113,8 @@ DEBUG_LEVEL = 'dbgl'
|
||||
DEBUG_REDACTION = 'dbrd'
|
||||
# Decoded ID token
|
||||
DECODED_ID_TOKEN = 'didt'
|
||||
# Developer Preview APIs
|
||||
DEVELOPER_PREVIEW_APIS = 'dapi'
|
||||
# Index of start of <UserTypeEntity> in command line
|
||||
ENTITY_CL_DELAY_START = 'ecld'
|
||||
ENTITY_CL_START = 'ecls'
|
||||
@@ -125,6 +129,8 @@ GAM_CFG_SECTION_NAME = 'gcsn'
|
||||
GAM_PATH = 'gpth'
|
||||
# Python source, PyInstaller or StaticX?
|
||||
GAM_TYPE = 'gtyp'
|
||||
# Shared Service Account HTTP Object
|
||||
HTTP_OBJECT = 'http'
|
||||
# Length of last Got message
|
||||
LAST_GOT_MSG_LEN = 'lgml'
|
||||
# License SKUs
|
||||
@@ -246,6 +252,7 @@ Globals = {
|
||||
CSV_OUTPUT_HEADER_FILTER: [],
|
||||
CSV_OUTPUT_HEADER_FORCE: [],
|
||||
CSV_OUTPUT_HEADER_ORDER: [],
|
||||
CSV_OUTPUT_HEADER_REQUIRED: [],
|
||||
CSV_OUTPUT_NO_ESCAPE_CHAR: None,
|
||||
CSV_OUTPUT_QUOTE_CHAR: None,
|
||||
CSV_OUTPUT_ROW_DROP_FILTER: [],
|
||||
@@ -267,6 +274,7 @@ Globals = {
|
||||
DEBUG_LEVEL: 0,
|
||||
DEBUG_REDACTION: True,
|
||||
DECODED_ID_TOKEN: None,
|
||||
DEVELOPER_PREVIEW_APIS: set(),
|
||||
ENTITY_CL_DELAY_START: 1,
|
||||
ENTITY_CL_START: 1,
|
||||
EXTRA_ARGS_LIST: [],
|
||||
@@ -276,6 +284,7 @@ Globals = {
|
||||
GAM_CFG_SECTION_NAME: '',
|
||||
GAM_PATH: '.',
|
||||
GAM_TYPE: '',
|
||||
HTTP_OBJECT: None,
|
||||
LAST_GOT_MSG_LEN: 0,
|
||||
LICENSE_SKUS: [],
|
||||
MAKE_BUILDING_ID_NAME_MAP: True,
|
||||
|
||||
@@ -236,6 +236,7 @@ DATA_TRANSFER_COMPLETED = 'Data Transfer completed: {0}\n'
|
||||
DATA_UPLOADED_TO_DRIVE_FILE = 'Data uploaded to Drive File'
|
||||
DEFAULT_SMIME = 'Default S/MIME'
|
||||
DELETED = 'Deleted'
|
||||
DEVELOPER_PREVIEW_REQUIRED = 'Developer Preview is required for this command\n'
|
||||
DEVICE_LIST_BUG = 'GAM hit Google internal bug 237397223. Please file a Google Support ticket stating that you are encountering this bug.'
|
||||
DEVICE_LIST_BUG_WORKAROUND_NOT_POSSIBLE = 'GAM workaround for this issue only works if orderby argument is not used and query does not contain \'register\'.'
|
||||
DEVICE_LIST_BUG_ATTEMPTING_WORKAROUND = 'GAM is attempting to work around the bug by filtering for devices created on or after the newest we\'ve seen ({0})...\n'
|
||||
|
||||
@@ -30,8 +30,8 @@
|
||||
- [Update an existing Service Account key](#update-an-existing-service-account-key)
|
||||
- [Replace all existing Service Account keys](#replace-all-existing-service-account-keys)
|
||||
- [Delete Service Account keys](#delete-service-account-keys)
|
||||
- [Upload a Service Account key to a service account with no keys](#upload-a-service-account-key-to-a-service-account-with-no-keys)
|
||||
- [Display Service Account keys](#display-service-account-keys)
|
||||
- [Upload a Service Account key to a service account without a valid private key](#upload-a-service-account-key-to-a-service-account-without-a-valid-private-key)
|
||||
- [Manage Service Account access](#manage-service-account-access)
|
||||
- [Full Service Account access](#full-service-account-access)
|
||||
- [Selective Service Account access](#selective-service-account-access)
|
||||
@@ -781,6 +781,14 @@ Here are some sample values:
|
||||
Create a new Service Account private key; all existing private keys remain valid.
|
||||
The `oauth2service.json` file is updated with the new private key.
|
||||
|
||||
This command requires that the current Service Account private key is valid, if you get the following error:
|
||||
```
|
||||
ERROR: 401: authError - Request had invalid authentication credentials.
|
||||
Expected OAuth 2 access token, login cookie or other valid authentication credential.
|
||||
See https://developers.google.com/identity/sign-in/web/devconsole-project.
|
||||
```
|
||||
see: [Upload a Service Account key to a service account without a valid private key](#upload-a-service-account-key-to-a-service-account-without-a-valid-private-key)
|
||||
|
||||
Keep a good record of where each Service Account key is used as the keys themselves do not record this information.
|
||||
|
||||
The two forms of the command are equivalent; the second form is used by Legacy GAM.
|
||||
@@ -809,6 +817,14 @@ The `oauth2service.json` file is updated with the new private key. If you had pr
|
||||
this `oauth2service.json` file to other users, you must redistribute the updated file as the private key
|
||||
in the distributed copies has been revoked.
|
||||
|
||||
This command requires that the current Service Account private key is valid, if you get the following error:
|
||||
```
|
||||
ERROR: 401: authError - Request had invalid authentication credentials.
|
||||
Expected OAuth 2 access token, login cookie or other valid authentication credential.
|
||||
See https://developers.google.com/identity/sign-in/web/devconsole-project.
|
||||
```
|
||||
see: [Upload a Service Account key to a service account without a valid private key](#upload-a-service-account-key-to-a-service-account-without-a-valid-private-key)
|
||||
|
||||
The two forms of the command are equivalent; the second form is used by Legacy GAM.
|
||||
```
|
||||
gam update sakey
|
||||
@@ -828,6 +844,14 @@ in the distributed copies has been revoked.
|
||||
|
||||
This command can be used if your Service Account keys have been compromised; all existing private keys are revoked.
|
||||
|
||||
This command requires that the current Service Account private key is valid, if you get the following error:
|
||||
```
|
||||
ERROR: 401: authError - Request had invalid authentication credentials.
|
||||
Expected OAuth 2 access token, login cookie or other valid authentication credential.
|
||||
See https://developers.google.com/identity/sign-in/web/devconsole-project.
|
||||
```
|
||||
see: [Upload a Service Account key to a service account without a valid private key](#upload-a-service-account-key-to-a-service-account-without-a-valid-private-key)
|
||||
|
||||
The two forms of the command are equivalent; the second form is used by Legacy GAM.
|
||||
```
|
||||
gam replace sakeys
|
||||
@@ -844,25 +868,20 @@ You can delete Service Accounts keys thus revoking access for that key. Generall
|
||||
delete a service account key for a distributed copy of an `oauth2service.json` file to disable
|
||||
that user's service account access.
|
||||
|
||||
This command requires that the current Service Account private key is valid, if you get the following error:
|
||||
```
|
||||
ERROR: 401: authError - Request had invalid authentication credentials.
|
||||
Expected OAuth 2 access token, login cookie or other valid authentication credential.
|
||||
See https://developers.google.com/identity/sign-in/web/devconsole-project.
|
||||
```
|
||||
see: [Upload a Service Account key to a service account without a valid private key](#upload-a-service-account-key-to-a-service-account-without-a-valid-private-key)
|
||||
|
||||
You can disable your current Service Account key if you specify the `doit` argument. This is your
|
||||
acknowledgement that you will have to manually create a new Service Account key in the Developer's Console
|
||||
or upload a new key with the `gam upload sakey` command.
|
||||
```
|
||||
gam delete sakeys <ServiceAccountKeyList>+ [doit]
|
||||
```
|
||||
## Upload a Service Account key to a service account with no keys
|
||||
There are two cases where you will use this command:
|
||||
* Your workspace is configured to disable service account private key uploads and you are creating a project.
|
||||
* All of your service account keys have been deleted, either manually or with the `gam delete sakeys` command.
|
||||
|
||||
The `oauth2service.json` file is updated with the new private key. If you had previously distributed
|
||||
any `oauth2service.json` file to other users, you must redistribute the updated file with the new key.
|
||||
```
|
||||
gam upload sakey [admin <EmailAddress>]
|
||||
(algorithm KEY_ALG_RSA_1024|KEY_ALG_RSA_2048)|
|
||||
(localkeysize 1024|2048|4096 [validityhours <Number>])|
|
||||
(yubikey yubikey_pin yubikey_slot AUTHENTICATION|SIGNATURE yubikey_serialnumber <Number>)
|
||||
```
|
||||
## Display Service Account keys
|
||||
There are system keys and user keys; user keys are what Gam uses; GCP uses system keys.
|
||||
|
||||
@@ -876,6 +895,19 @@ gam show sakeys [all|system|user]
|
||||
|
||||
The private key currently being used in `oauth2service.json` will be marked as `usedToAuthenticateThisRequest: True`.
|
||||
|
||||
## Upload a Service Account key to a service account without a valid private key
|
||||
There are two cases where you will use this command:
|
||||
* Your workspace is configured to disable service account private key uploads and you are creating a project.
|
||||
* All of your service account keys have been deleted, either manually or with the `gam delete sakeys` command.
|
||||
|
||||
The `oauth2service.json` file is updated with the new private key. If you had previously distributed
|
||||
any `oauth2service.json` file to other users, you must redistribute the updated file with the new key.
|
||||
```
|
||||
gam upload sakey [admin <EmailAddress>]
|
||||
(algorithm KEY_ALG_RSA_1024|KEY_ALG_RSA_2048)|
|
||||
(localkeysize 1024|2048|4096 [validityhours <Number>])|
|
||||
(yubikey yubikey_pin yubikey_slot AUTHENTICATION|SIGNATURE yubikey_serialnumber <Number>)
|
||||
```
|
||||
## Manage Service Account access
|
||||
|
||||
## Full Service Account access
|
||||
|
||||
@@ -283,6 +283,8 @@
|
||||
<ChatEmoji> ::= emojiname <ChatEmojiName> | customemojis/<String>
|
||||
<ChatMember> ::= spaces/<String>/members/<String>
|
||||
<ChatMessage> ::= spaces/<String>/messages/<String>
|
||||
<ChatSection> ::= users/<String>/sections/<String> | sections/<String> | section <String>
|
||||
<ChatSectionItem> ::= users/<String>/sections/<String>/items/<String> | sections/<String>/items/<String>
|
||||
<ChatSpace> ::= spaces/<String> | space <String> | space spaces/<String>
|
||||
<ChatThread> ::= spaces/<String>/threads/<String>
|
||||
<ChromeProfilePermanentID> ::= <String>
|
||||
@@ -409,6 +411,8 @@
|
||||
<MatterItem> ::= <UniqueID>|<String>
|
||||
<MatterState> ::= open|closed|deleted
|
||||
<MeetConferenceName> ::= conferenceRecords/<String>
|
||||
<MeetID> ::= <String>
|
||||
Must match this Python Regular Expression: [a-z]{3}-[a-z]{4}-[a-z]{3}
|
||||
<MeetSpaceName> ::= spaces/<String> | <String>
|
||||
<MessageContent> ::=
|
||||
(message|textmessage|htmlmessage <String>)|
|
||||
@@ -424,6 +428,7 @@
|
||||
(gdoc|ghtml <UserGoogleDoc>)|
|
||||
(gcsdoc|gcshtml <StorageBucketObjectName>)
|
||||
<NumberOfSeats> ::= <Number>
|
||||
<NumberRange> ::= <Number>|(<Number>/<Number>)
|
||||
<OrgUnitID> ::= id:<String>
|
||||
<OrgUnitPath> ::= /|(/<String>)+
|
||||
<OrgUnitItem> ::= <OrgUnitID>|<OrgUnitPath>
|
||||
@@ -564,11 +569,11 @@
|
||||
(tdreturnidonly [<Boolean>])|
|
||||
(tdshare <EmailAddress> commenter|reader|writer)*|
|
||||
(tdsheet (id:<Number>)|<String>)|
|
||||
(tdsheettimestamp [<Boolean>] [tdsheettimeformat <String>])
|
||||
(tdsheettimestamp [<Boolean>] [tdsheettimeformat <DateTimeFormat>])
|
||||
(tdsheettitle <String>)|
|
||||
(tdsubject <String>)|
|
||||
([tdsheetdaysoffset <Number>] [tdsheethoursoffset <Number>])|
|
||||
(tdtimestamp [<Boolean>] [tdtimeformat <String>]
|
||||
(tdtimestamp [<Boolean>] [tdtimeformat <DateTimeFormat>]
|
||||
[tddaysoffset <Number>] [tdhoursoffset <Number>])|
|
||||
(tdtimezone <TimeZone>)|
|
||||
(tdtitle <String>)|
|
||||
|
||||
@@ -38,6 +38,7 @@ Batch files can contain the following types of lines:
|
||||
* Blank lines - Ignored
|
||||
* \# Comment line - Ignored
|
||||
* gam \<GAMArgumentList\> - Execute a GAM command
|
||||
* File path arguments in \<GAMArgumentList\> should be enclosed in \"
|
||||
* commit-batch
|
||||
* GAM waits for all running GAM commands to complete
|
||||
* GAM continues
|
||||
|
||||
@@ -14,8 +14,9 @@
|
||||
There are seven values in `gam.cfg` that can be used to filter the output from `gam print` commands.
|
||||
* `csv_output_header_filter` - A list of `<RegularExpressions>` used to select specific column headers to include
|
||||
* `csv_output_header_drop_filter` - A list of `<RegularExpressions>` used to select specific column headers to exclude
|
||||
* `csv_output_header_force` - A list of <Strings> used to specify the exact column headers to include
|
||||
* `csv_output_header_order` - A list of <Strings> used to specify the column header order; any headers in the file but not in the list will appear after the headers in the list.
|
||||
* `csv_output_header_force` - A list of `<Strings>` used to specify the exact column headers to include
|
||||
* `csv_output_header_order` - A list of `<Strings>` used to specify the column header order; any headers in the file but not in the list will appear after the header* `csv_output_header_required` - A list of `<Strings>` used to specify column headers that are included even if the print command doesn't return them
|
||||
s in the list.
|
||||
* `csv_output_row_filter` - A list or JSON dictionary used to include specific rows based on column values
|
||||
* `csv_output_row_drop_filter` - A list or JSON dictionary used to exclude specific rows based on column values
|
||||
* `csv_output_row_limit` - A limit on the number of rows written
|
||||
|
||||
@@ -78,6 +78,8 @@ Client access works when accessing Resource calendars.
|
||||
<CSVkmdSelector> | <CSVDataSelector>
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Items
|
||||
<iCalUID> ::= <String>
|
||||
<MeetID> ::= <String>
|
||||
Must match this Python Regular Expression: [a-z]{3}-[a-z]{4}-[a-z]{3}
|
||||
|
||||
<EventAttachmentsSubfieldName> ::=
|
||||
attachments.fileid|
|
||||
@@ -150,7 +152,8 @@ Client access works when accessing Resource calendars.
|
||||
endtimeunspecified|
|
||||
extendedproperties|
|
||||
eventtype|
|
||||
<EventFocusTimePropertiesSubfieldName>
|
||||
focustimeproperties|
|
||||
<EventFocusTimePropertiesSubfieldName>|
|
||||
gadget|
|
||||
guestscaninviteothers|
|
||||
guestscanmodify|
|
||||
@@ -164,7 +167,8 @@ Client access works when accessing Resource calendars.
|
||||
organizer|
|
||||
<EventOrganizerSubfieldName>|
|
||||
originalstart|originalstarttime|
|
||||
<EventOutOfOfficePropertiesSubfieldName>
|
||||
outofofficeproperties|
|
||||
<EventOutOfOfficePropertiesSubfieldName>|
|
||||
privatecopy|
|
||||
recurrence|
|
||||
recurringeventid|
|
||||
@@ -254,6 +258,7 @@ Client access works when accessing Resource calendars.
|
||||
(birthday <Date>)|
|
||||
(color <EventColorName>)|
|
||||
(colorindex|colorid <EventColorIndex>)|
|
||||
(conferencedata meet <MeetID>)|
|
||||
(description <String>)|
|
||||
(end|endtime (allday <Date>)|<Time>)|
|
||||
(guestscaninviteothers <Boolean>)|
|
||||
@@ -511,11 +516,16 @@ Use `jsonattendees file ./attendees.json` in `create/update event`.
|
||||
|
||||
## Delete selected calendar events
|
||||
```
|
||||
gam calendar <CalendarEntity> delete events [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam calendar <CalendarEntity> purge events [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam calendar <CalendarEntity> delete events [<EventEntity>]
|
||||
[batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
gam calendar <CalendarEntity> purge events [<EventEntity>]
|
||||
[batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
```
|
||||
If `<EventEntity>` is not specified, all events in `<CalendarEntity>` are selected. This is not typically used.
|
||||
|
||||
By default, each event is deleted in a separate API call, use `batchsize` with an integer between 1 and 1000
|
||||
to delete the events in batches.
|
||||
|
||||
No events are deleted unless you specify the `doit` option; omit `doit` to verify that you properly selected the events to delete.
|
||||
|
||||
When events are deleted from a calendar, they are moved to the calendar's trash and are only permanently deleted (purged) after 30 days.
|
||||
@@ -585,7 +595,7 @@ By default, Gam displays event details, use `countsonly` to display only the num
|
||||
|
||||
```
|
||||
gam calendar <CalendarEntity> print events [<EventEntity>] <EventDisplayProperty>*
|
||||
[fields <EventFieldNameList>] [showdayofweek]
|
||||
[fields <EventFieldNameList>] [showdayofweek] [attendeeslist]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
[eventrowfilter]
|
||||
[countsonly|(formatjson [quotechar <Character>])] [todrive <ToDriveAttribute>*]
|
||||
@@ -599,6 +609,10 @@ option `singleevents` to display all instances of a recurring event.
|
||||
|
||||
`showdayofweek` displays columns `start.dayOfWeek` and `end.dayOfWeek` when event start and end times are displayed.
|
||||
|
||||
By default, each attendee is displayed in a separate column; `attendeeslist` causes GAM to display
|
||||
the attendee email addresses in a single column `attendeesList`; no attendee details are displayed.
|
||||
The email addresses are separated by `csv_output_field_delimiter` from `gam.cfg`.
|
||||
|
||||
Add additional columns of data from the command line to the output after the calendarId.
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
|
||||
@@ -282,10 +282,11 @@ gam show chromepolicies
|
||||
((ou|orgunit <OrgUnitItem> [show all|direct|inherited])|(group <GroupItem>))
|
||||
[(printerid <PrinterID>)|(appid <AppID>)]
|
||||
[filter <StringList>] [namespace <NamespaceList>]
|
||||
[show all|direct|inherited]
|
||||
[formatjson]
|
||||
```
|
||||
By default, all Chrome policies for the OU or group are displayed.
|
||||
* `filter <String>` - Display policies based on fields like its resource name, description and additionalTargetKeyNames.
|
||||
* `filter <StringList>` - Display policies based on fields like its resource name, description and additionalTargetKeyNames.
|
||||
* `show all` - For OUs, display policies regardless of where set; this is the default
|
||||
* `show direct` - For OUs, display policies set directly in the OU
|
||||
* `show inherited` - For OUs, display policies set in a parent OU
|
||||
@@ -329,15 +330,25 @@ By default, Gam displays the information as an indented list of keys and values.
|
||||
gam print chromepolicies [todrive <ToDriveAttribute>*]
|
||||
((ou|orgunit <OrgUnitItem> [show all|direct|inherited])|(group <GroupItem>))
|
||||
[(printerid <PrinterID>)|(appid <AppID>)]
|
||||
[filter <String>] [namespace <NamespaceList>]
|
||||
[filter <StringList>] [namespace <NamespaceList>]
|
||||
[show all|direct|inherited] [shownopolicy]
|
||||
[[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, all Chrome policies for the OU or group are displayed.
|
||||
* `filter <String>` - Display policies based on fields like its resource name, description and additionalTargetKeyNames.
|
||||
* `filter <StringList>` - Display policies based on fields like its resource name, description and additionalTargetKeyNames.
|
||||
* `show all` - For OUs, display policies regardless of where set; this is the default
|
||||
* `show direct` - For OUs, display policies set directly in the OU
|
||||
* `show inherited` - For OUs, display policies set in a parent OU
|
||||
|
||||
Use option `shownopolicy` to display output like the following if no policies apply to the OU or group.
|
||||
```
|
||||
gam print chromepolicies ou /Test appid chrome:emidddocikgklceeeifefomdnbkldhng namespace chrome.users.apps shownopolicy
|
||||
Getting all Chrome Policies that match query (chrome.users.apps.*) for /Test
|
||||
Got 0 Chrome Policies that matched query (chrome.users.apps.*) for /Test...
|
||||
name,orgUnitPath,parentOrgUnitPath,direct,appId
|
||||
noPolicy,/Test,/,False,chrome:emidddocikgklceeeifefomdnbkldhng
|
||||
```
|
||||
|
||||
These are the default namespaces; use `namespace <NamespaceList>` to override.
|
||||
* `default`
|
||||
* chrome.users
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
- [Action ChromeOS devices](#action-chromeos-devices)
|
||||
- [Send remote commands to ChromeOS devices](#send-remote-commands-to-chromeos-devices)
|
||||
- [Action Examples](#action-examples)
|
||||
- [Bulk Action Example](#bulk-action-example)
|
||||
- [ChromeOS device lists](#chromeos-device-lists)
|
||||
- [Display information about ChromeOS devices](#display-information-about-chromeos-devices)
|
||||
- [Print ChromeOS devices](#print-chromeos-devices)
|
||||
@@ -445,12 +446,19 @@ is configurable from 0 to some large number. If the status reaches `EXPIRED`, `C
|
||||
wipe_users|
|
||||
take_a_screenshot
|
||||
|
||||
gam <CrOSTypeEntity> issuecommand command <CrOSCommand> [times_to_check_status <Integer>] [doit]
|
||||
gam <CrOSTypeEntity> issuecommand command <CrOSCommand>
|
||||
[times_to_check_status <Integer>] [csv] [doit]
|
||||
```
|
||||
By default, when a Chrome command is issued, GAM outputs details of the command status as indented keywords and values.
|
||||
* `csv` - Output the details in CSV format.
|
||||
|
||||
If the final status is not reached before GAM exits, you can issue the following commands to continue checking the status.
|
||||
```
|
||||
gam <CrOSTypeEntity> getcommand commandid <CommandID> [times_to_check_status <Integer>]
|
||||
gam <CrOSTypeEntity> getcommand commandid <CommandID>
|
||||
[times_to_check_status <Integer>] [csv]
|
||||
```
|
||||
By default, when a Chrome command status is read, GAM outputs details of the command status as indented keywords and values.
|
||||
* `csv` - Output the details in CSV format.
|
||||
|
||||
### Action Examples
|
||||
Remove user profile data from the device; the device will remain enrolled and connected.
|
||||
@@ -476,6 +484,40 @@ Use `wipe_users` if that's going to create too much work for you.
|
||||
```
|
||||
gam cros_ou /StudentCarts issuecommand command remote_powerwash times_to_check_status 0 doit
|
||||
```
|
||||
|
||||
### Bulk Action example
|
||||
You want to issue commands to many ChromeOS devices and monitor the results.
|
||||
|
||||
Assume a Google Sheet with two tabs: Commands and Results
|
||||
The Commands tab has at least two columns: serialNumber and command
|
||||
```
|
||||
serialNumber,command
|
||||
abc123def123,reboot
|
||||
abc123def456,remote_powerwash
|
||||
abc123def789,wipe_users
|
||||
```
|
||||
Here is the URL for the Commands tab
|
||||
```
|
||||
https://docs.google.com/spreadsheets/d/12349lNWvZwzJhwxyz/edit?gid=1588227640#gid=1588227640
|
||||
<SheetFileID> = 12349lNWvZwzJhwxyz
|
||||
<CommandTabID> = 1588227640
|
||||
Here is the URL for the Commands tab
|
||||
https://docs.google.com/spreadsheets/d/12349lNWvZwzJhwxyz/edit?gid=2102420937#gid=2102420937
|
||||
<SheetFileID> = 12349lNWvZwzJhwxyz
|
||||
<ResultsTabID> = 2102420937
|
||||
```
|
||||
Replace `user@domain.com` with the email address of the Google Sheet owner.
|
||||
|
||||
Issue the commands from the Commands tab and write the results to the Results tab; copy the `serialNumber` to the Results tab.
|
||||
```
|
||||
gam config num_threads 20 redirect csv - multiprocess sortheaders serialNumber todrive tduser user@domain.com tdfileID <SheetFileID> tdsheet id:<ResultsTabID> tdupdatesheet tdretaintitle redirect stderr - multiprocess csv gsheet user@domain.com <SheetFileID> id:<CommandsTabID> gam cros_sn "~serialNumber" issuecommand command "~command" doit csv addcsvdata serialNumber "~serialNumber"
|
||||
```
|
||||
Monitor the results by reading and updating the results from/to the Results tab; copy the `serialNumber` to the Results tab.
|
||||
```
|
||||
gam config num_threads 20 redirect csv - multiprocess sortheaders serialNumber todrive tduser user@domain.com tdfileID <SheetFileID> tdsheet id:<ResultsTabID> tdupdatesheet tdretaintitle redirect stderr - multiprocess csv gsheet user@domain.com <SheetFileID> id:<ResultsTabID> gam cros "~deviceId" getcommand commandid "~commandId" csv addcsvdata serialNumber "~serialNumber"
|
||||
```
|
||||
You can use additional `addcsvdata` options to copy device identifying information from the source to the destination.
|
||||
|
||||
## ChromeOS device lists
|
||||
ChromeOS devices have lists of data: `<CrOSListFieldName>`, `<CrOSActivityListFieldName>`, `<CrOSTelemetryListFieldName>`.
|
||||
All lists except `recentusers` are in ascending order (oldest to newest). As these lists can contain many entries,
|
||||
@@ -544,7 +586,7 @@ gam print cros [todrive <ToDriveAttribute>*]
|
||||
[start <Date>] [end <Date>] [listlimit <Number>]
|
||||
[reverselists <CrOSListFieldNameList>]
|
||||
[timerangeorder ascending|descending] [showdvrsfp]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[sortheaders]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
@@ -591,9 +633,11 @@ Add additional columns of data from the command line to the output
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format:
|
||||
|
||||
- `formatjson` - Display the fields in JSON format.
|
||||
|
||||
If `formatjson` and `addcsvdata` are specified, the option `includecsvdatainjson` causes GAM to add the
|
||||
additional field values to the JSON data.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
@@ -612,7 +656,7 @@ gam <CrOSTypeEntity> print cros [todrive <ToDriveAttribute>*]
|
||||
[start <Date>] [end <Date>] [listlimit <Number>]
|
||||
[reverselists <CrOSListFieldNameList>]
|
||||
[timerangeorder ascending|descending] [showdvrsfp]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[sortheaders]
|
||||
[formatjson [quotechar <Character>]]
|
||||
|
||||
@@ -623,6 +667,7 @@ gam print cros [todrive <ToDriveAttribute>*] select <CrOSTypeEntity>
|
||||
[start <Date>] [end <Date>] [listlimit <Number>]
|
||||
[reverselists <CrOSListFieldNameList>]
|
||||
[timerangeorder ascending|descending] [showdvrsfp]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[sortheaders]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
@@ -645,9 +690,11 @@ Add additional columns of data from the command line to the output
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format:
|
||||
|
||||
- `formatjson` - Display the fields in JSON format.
|
||||
|
||||
If `formatjson` and `addcsvdata` are specified, the option `includecsvdatainjson` causes GAM to add the
|
||||
additional field values to the JSON data.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
|
||||
@@ -12,33 +12,8 @@
|
||||
- [Display student group membership counts](#display-student-group-membership-counts)
|
||||
|
||||
## Notes
|
||||
These commands wera added in version 7.20.00.
|
||||
|
||||
To use these commands your project must be enrolled the Developer Preview program.
|
||||
* https://developers.google.com/workspace/preview
|
||||
|
||||
You will need your GAM project number.
|
||||
* Login as an existing super admin at console.cloud.google.com
|
||||
* In the upper left click the three lines to the left of Google Cloud and select IAM & Admin
|
||||
* Under IAM & Admin select IAM
|
||||
* Click in the box to the right of Google Cloud
|
||||
* Click the three dots at the right and select Manage Resources
|
||||
* Click the three dots at the end of the line for your GAM project
|
||||
* Click Settings
|
||||
* You will see the Project number; save it
|
||||
|
||||
You will need an API key
|
||||
* In the upper left click the three lines to the left of Google Cloud and select APIs & Services
|
||||
* Under APIs & Services select Credentials
|
||||
* If you already have an API key, click Show key at the end of the line and save the value
|
||||
* If you don't have an API key, click +Credentials and select API key
|
||||
* Save the displayed API key
|
||||
* Click close
|
||||
|
||||
Issue the following GAM command:
|
||||
`gam config developer_preview_api_key <API Key Value> save`
|
||||
|
||||
Once you get an email from Google saying that your project has been registered you can use these commands.
|
||||
These commands were added in version 7.20.00 and required enrollment in the Developer Preview program.
|
||||
As of 7.32.04 Developer Preview enrollment is no longer required.
|
||||
|
||||
## API documentation
|
||||
* [Google Classroom API](https://developers.google.com/classroom/reference/rest)
|
||||
@@ -122,7 +97,7 @@ gam clear course-studentgroups
|
||||
(course|class <CourseEntity>)*|([teacher <UserItem>] [student <UserItem>] [states <CourseStateList>])
|
||||
```
|
||||
|
||||
When creating student groups, the API does not check for duplicate titles; you can have multiple student grpups
|
||||
When creating student groups, the API does not check for duplicate titles; you can have multiple student groups
|
||||
with the same title; they will have unique `<StudentGroupID>s`.
|
||||
|
||||
The `update|delete course-studentgroups` commands manage a specific course.
|
||||
|
||||
@@ -40,6 +40,18 @@ Use `gam user user@domain.com update serviceaccount` and make sure that the foll
|
||||
* [Filters](https://support.google.com/a/answer/7549103)
|
||||
* [Device Search Fields](https://developers.google.com/admin-sdk/directory/v1/search-operators)
|
||||
|
||||
Use this table to filter/query for specific device types:
|
||||
| Device Type | Filter/Query |
|
||||
|-------------|--------------|
|
||||
| ANDROID | type:android |
|
||||
| CHROME_OS | type:chromeos |
|
||||
| GOOGLE_SYNC | type:googlesync |
|
||||
| IOS | type:ios |
|
||||
| LINUX | type:linux |
|
||||
| MAC_OS | type:mac |
|
||||
| WINDOWS | type:windows |
|
||||
|
||||
|
||||
## Definitions
|
||||
```
|
||||
<AssetTag> ::= <String>
|
||||
@@ -370,7 +382,6 @@ Windows Command Prompt
|
||||
for /f "delims=" %a in ('gam print deviceusers queries "'model:Mac'" showitemcountonly') do set count=%a
|
||||
```
|
||||
|
||||
|
||||
## Display device user client state
|
||||
```
|
||||
gam info deviceuserstate <DeviceUserEntity> [clientid <String>]
|
||||
@@ -379,11 +390,11 @@ gam info deviceuserstate <DeviceUserEntity> [clientid <String>]
|
||||
## Update device user client state
|
||||
The API that supports this command is in beta mode. In particular, setting `assettags` and `customvalues`
|
||||
works if you set the values once; each additional time you set values they are added to the existing values
|
||||
and they is no way at the moment to clear values.
|
||||
and the `clear` option does not work to clear values.
|
||||
```
|
||||
gam update deviceuserstate <DeviceUserEntity> [clientid <String>]
|
||||
[customid <String>] [assettags clear|<AssetTagList>]
|
||||
[compliantstate|compliancestate compliant|noncompliant] [managedstate clear|managed|unmanaged]
|
||||
[healthscore very_poor|poor|neutral|good|very_good] [scorereason clear|<String>]
|
||||
(customvalue (bool|boolean <Boolean>)|(number <Integer>)|(string <String>))*
|
||||
(customvalue clear|(bool|boolean <String> <Boolean>)|(number <String> <Integer>)|(string <String> <String>))*
|
||||
```
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
- [Display user group member options](#display-user-group-member-options)
|
||||
- [Display group membership in CSV format](#display-group-membership-in-csv-format)
|
||||
- [Display group membership in hierarchical format](#display-group-membership-in-hierarchical-format)
|
||||
|
||||
- [Manage external users in groups with allowExternalMembers False](#manage-external-users-in-groups-with-allowexternalmembers-false)
|
||||
## API documentation
|
||||
* [Cloud Identity Groups Overview](https://cloud.google.com/identity/docs/groups)
|
||||
* [Cloud Identity Groups API - Groups](https://cloud.google.com/identity/docs/reference/rest/v1/groups)
|
||||
@@ -349,11 +349,15 @@ gam print cigroup-members [todrive <ToDriveAttribute>*]
|
||||
[emailmatchpattern [not] <REMatchPattern>] [namematchpattern [not] <REMatchPattern>]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[verifyallowexternal [<Boolean>]]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
<CIGroupMembersFieldName>* [fields <CIGroupMembersFieldNameList>]
|
||||
[minimal|basic|full]
|
||||
[(recursive [noduplicates]) | |includederivedmembership] [nogroupeemail]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, the group membership of all groups in the account are displayed, these options allow selection of subsets of groups:
|
||||
* `cimember <UserItem>` - Limit display to groups that contain `<UserItem>` as a member
|
||||
@@ -378,6 +382,24 @@ By default, all members, managers and owners in the group are displayed; these o
|
||||
By default, all types of members (cbcmbrowser, chromeosdevice, customer, group, serviceaccount, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <CIGroupMemberTypeList>` - Display specified types
|
||||
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
Members without an email address, e.g. `customer`, `chrome-os-device` and `cbcm-browser` are considered `internal`.
|
||||
|
||||
When the `internal` or `external` options are specified, GAM adds the column `allowExternalMembers`
|
||||
that shows that setting for the group and adds the column `category` that shows whether the member
|
||||
is `external` or `internal`.
|
||||
|
||||
The option `verifyallowexternal` causes GAM to only display `external` users in groups with `allowExternalMembers=False'.
|
||||
|
||||
By default, members that are groups are displayed as a single entry of type GROUP; this option recursively expands group members to display their user members.
|
||||
* `recursive` - Recursively expand group members
|
||||
|
||||
@@ -414,6 +436,9 @@ has in any constituent group, it is not necessarily its role in the top group.
|
||||
The options `recursive noduplicates` and `includederivedmembership types user` return the same list of users.
|
||||
The `includederivedmembership` option makes less API calls but doesn't show level and subgroup information.
|
||||
|
||||
Add additional columns of data from the command line to the output
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
@@ -430,9 +455,10 @@ gam show cigroup-members
|
||||
[emailmatchpattern [not] <REMatchPattern>] [namematchpattern [not] <REMatchPattern>]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[minimal|basic|full]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[(depth <Number>) | includederivedmembership]
|
||||
```
|
||||
By default, the group membership of all groups in the account are displayed, these options allow selection of subsets of groups:
|
||||
@@ -458,6 +484,18 @@ By default, all members, managers and owners in the group are displayed; these o
|
||||
By default, all types of members (cbcmbrowser, chromeosdevice, customer, group, serviceaccount, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <CIGroupMemberTypeList>` - Display specified types
|
||||
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
Members without an email address, e.g. `customer`, `chrome-os-device` and `cbcm-browser` are considered `internal`.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
* `memberemailskippattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will not be displayed; others will be displayed
|
||||
@@ -495,3 +533,41 @@ To show the structure of all groups you can do the following; it will be time co
|
||||
```
|
||||
gam redirect stdout ./groups.txt show cigroup-members types group
|
||||
```
|
||||
|
||||
## Manage external users in groups with allowExternalMembers False
|
||||
|
||||
* See: https://support.google.com/a/answer/16778447
|
||||
|
||||
Get external members of groups with allowExternalMembers = False
|
||||
```
|
||||
gam redirect csv ./ExternalMembersGroupsWithAEMFalse.csv print cigroup-members verifyallowexternal
|
||||
```
|
||||
|
||||
Update selected groups to allowExternalMembers = True
|
||||
* Add a column labelled `update` to ExternalMembersGroupsWithAEMFalse.csv
|
||||
* For groups to be updated, add an x to the `update` column for any member of the group to be updated
|
||||
```
|
||||
gam redirect stdout ./UpdateGroupsWithAEMFalseToAEMTrue.txt redirect stderr stdout update group csvkmd ExternalMembersGroupsWithAEMFalse.csv keyfield group matchfield update x allowexternalmembers true
|
||||
```
|
||||
|
||||
Update all groups to allowExternalMembers = True
|
||||
**Caution, be sure that this is what you want**
|
||||
```
|
||||
gam redirect stdout ./UpdateGroupsWithAEMFalseToEMTrue.txt redirect stderr stdout update group csvkmd ExternalMembersGroupsWithAEMFalse.csv keyfield group allowexternalmembers true
|
||||
```
|
||||
|
||||
Delete selected external members from groups with allowExternalMembers = False
|
||||
* Add a column labelled `delete` to ExternalMembersGroupsWithAEMFalse.csv
|
||||
* For exernal members to be deleted, add an x to the `delete` column
|
||||
* The `preview` option let's you verify what external members are to be deleted, remove it to do the deletions
|
||||
```
|
||||
gam redirect csv ./DeletedMembersFromGroupsWithAEMFalse.csv redirect stdout ./DeleteMembersFromGroupsWithAEMFalse.txt redirect stderr stdout update group csvkmd ExternalMembersGroupsWithAEMFalse.csv keyfield group matchfield delete x datafield email delete preview actioncsv csvdata email
|
||||
```
|
||||
|
||||
Delete all external members from groups with allowExternalMembers = False
|
||||
**Caution, be sure that this is what you want**
|
||||
* The `preview` option let's you verify what external members are to be deleted, remove it to do the deletions
|
||||
```
|
||||
gam redirect csv ./DeletedMembersFromGroupsWithAEMFalse.csv redirect stdout ./DeleteMembersFromGroupsWithAEMFalse.txt redirect stderr stdout update group csvkmd ExternalMembersGroupsWithAEMFalse.csv keyfield group datafield email delete preview actioncsv csvdata email
|
||||
```
|
||||
|
||||
|
||||
@@ -267,7 +267,7 @@ gam info cigroups <GroupEntity>
|
||||
[nosecurity|nosecuritysettings]
|
||||
[allfields|<CIGroupFieldName>*|(fields <CIGroupFieldNameList>)]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[formatjson]
|
||||
@@ -283,13 +283,17 @@ By default, all direct members, managers and owners in the group are displayed;
|
||||
By default, when displaying members from a group, all types of members (customer, group, serviceaccount, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <CIGroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Members without an email address, e.g. `customer`, `chrome-os-device` and `cbcm-browser` are considered internal.
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
Members without an email address, e.g. `customer`, `chrome-os-device` and `cbcm-browser` are considered `internal`.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
@@ -317,11 +321,12 @@ gam print cigroups [todrive <ToDriveAttribute>*]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[basic|allfields|(<CIGroupFieldName>* [fields <CIGroupFieldNameList>])]
|
||||
[roles <GroupRoleList>] [memberrestrictions]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[members|memberscount] [managers|managerscount] [owners|ownerscount] [totalcount] [countsonly]
|
||||
[types <CIGroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[convertcrnl] [delimiter <Character>]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, all groups in the account are displayed, these options allow selection of subsets of groups:
|
||||
@@ -373,21 +378,34 @@ By default, no members, managers or owners in the group are displayed; these opt
|
||||
By default, when displaying members from a group, all types of members (customer, group, serviceaccount, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <CIGroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Members without an email address, e.g. `customer`, `chrome-os-device` and `cbcm-browser` are considered internal.
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
When the `internal` or `external` options are specified, GAM adds the column `allowExternalMembers`
|
||||
that shows that setting for the group.
|
||||
|
||||
Members without an email address, e.g. `customer`, `chrome-os-device` and `cbcm-browser` are considered `internal`.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
* `memberemailskippattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will not be displayed; others will be displayed
|
||||
|
||||
Add additional columns of data from the command line to the output
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
If `formatjson` and `addcsvdata` are specified, the option `includecsvdatainjson` causes GAM to add the
|
||||
additional field values to the JSON data.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
|
||||
@@ -319,6 +319,8 @@ Data fields identified in a `csvkmd` argument.
|
||||
(select <ProjectIDList> | <FileSelector> | <CSVFileSelector>)
|
||||
<PrinterIDEntity> ::=
|
||||
<PrinterIDList> | <FileSelector> | <CSVFileSelector>
|
||||
<QueryDriveFile> :: = <String> See: https://developers.google.com/workspace/drive/api/guides/search-files
|
||||
<QuerySharedDrive> ::= <String> See: https://developers.google.com/workspace/drive/api/guides/search-shareddrives
|
||||
<RecipientEntity> ::=
|
||||
<EmailAddressEntity> | (select <UserTypeEntity>)
|
||||
<ResourceEntity> ::=
|
||||
@@ -329,22 +331,22 @@ Data fields identified in a `csvkmd` argument.
|
||||
<SerialNumberList> | <FileSelector> | <CSVFileSelector>
|
||||
<SharedDriveIDEntity> ::=
|
||||
<DriveFileItem> |
|
||||
(teamdriveid <DriveFileItem>) | (teamdriveid:<DriveFileItem>)
|
||||
(shareddriveid <DriveFileItem>) | (shareddriveid:<DriveFileItem>)
|
||||
<SharedDriveNameEntity> ::=
|
||||
(teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
(shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveIDEntity> |
|
||||
<SharedDriveNameEntity>
|
||||
<SharedDriveAdminQueryEntity> ::=
|
||||
(teamdriveadminquery <QueryTeamDrive>) | (teamdriveadminquery:<QueryTeamDrive>)
|
||||
(shareddriveadminquery <QuerySharedDrive>) | (shareddriveadminquery:<QuerySharedDrive>)
|
||||
<SharedDriveEntityAdmin> ::=
|
||||
<SharedDriveIDEntity> |
|
||||
<SharedDriveNameEntity>|
|
||||
<SharedDriveAdminQueryEntity>
|
||||
<SharedDriveFileNameEntity> ::=
|
||||
(teamdrivefilename <DriveFileName>) | (teamdrivefilename:<DriveFileName>)
|
||||
(shareddrivefilename <DriveFileName>) | (shareddrivefilename:<DriveFileName>)
|
||||
<SharedDriveFileQueryEntity> ::=
|
||||
(teamdrivequery <QueryDriveFile>) | (teamdrivequery:<QueryDriveFile>)
|
||||
(shareddrivequery <QueryDriveFile>) | (shareddrivequery:<QueryDriveFile>)
|
||||
<SharedDriveFileQueryShortcut> ::=
|
||||
all_files | all_folders | all_google_files | all_non_google_files | all_items
|
||||
<SiteACLScopeEntity> ::=
|
||||
|
||||
@@ -114,9 +114,9 @@ ous_and_children_na_ns
|
||||
(anydrivefilename <DriveFileName>)|(anydrivefilename:<DriveFileName>)
|
||||
<SharedDriveID> ::= <String>
|
||||
<SharedDriveName> ::= <String>
|
||||
<SharedDriveIDEntity> ::= (teamdriveid <DriveFileItem>) | (teamdriveid:<DriveFileItem>)
|
||||
<SharedDriveNameEntity> ::= (teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (teamdrivefilename <DriveFileName>) | (teamdrivefilename:<DriveFileName>)
|
||||
<SharedDriveIDEntity> ::= (shareddriveid <DriveFileItem>) | (shareddriveid:<DriveFileItem>)
|
||||
<SharedDriveNameEntity> ::= (shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (shareddrivefilename <DriveFileName>) | (shareddrivefilename:<DriveFileName>)
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveIDEntity> |
|
||||
<SharedDriveNameEntity>
|
||||
@@ -327,7 +327,7 @@ Use these options to select users for GAM commands.
|
||||
* `ou_arch` - Archived users
|
||||
* `ou_ns` - Non-suspended users
|
||||
* `ou_susp` - Suspended users
|
||||
* `ou_na_ns` - Non-archived and nn-suspended users
|
||||
* `ou_na_ns` - Non-archived and non-suspended users
|
||||
|
||||
## Users in the Organization Unit `<OrgUnitItem>` and all of its sub Organization Units
|
||||
* `ou_and_children|ou_and_children_na|ou_and_children_arch|ou_and_children_ns|ou_and_children_susp|ou_and_children_na_ns <OrgUnitItem>`
|
||||
@@ -336,7 +336,7 @@ Use these options to select users for GAM commands.
|
||||
* `ou_and_children_arch` - Archived users
|
||||
* `ou_and_children_ns` - Non-suspended users
|
||||
* `ou_and_children_susp` - Suspended users
|
||||
* `ou_and_children_na_ns` - Non-archived and nn-suspended users
|
||||
* `ou_and_children_na_ns` - Non-archived and non-suspended users
|
||||
|
||||
## Users directly in the Organization Units `<OrgUnitList>`
|
||||
* `ous|ous_na|ous_arch|ous_ns|ous_susp|ous_na_ns <OrgUnitList>` - Users directly in the Organization Units `<OrgUnitList>`
|
||||
@@ -345,7 +345,7 @@ Use these options to select users for GAM commands.
|
||||
* `ous_arch` - Archived users
|
||||
* `ous_ns` - Non-suspended users
|
||||
* `ous_susp` - Suspended users
|
||||
* `ous_na_ns` - Non-archived and nn-suspended users
|
||||
* `ous_na_ns` - Non-archived and non-suspended users
|
||||
|
||||
`<OrgUnitList>` may require special quoting based on whether the OUs contain spaces, commas or single quotes.
|
||||
|
||||
|
||||
@@ -49,7 +49,8 @@
|
||||
<DriveFolderID> ::= <String>
|
||||
<DriveFolderIDList> ::= "<DriveFolderID>(,<DriveFolderID>)*"
|
||||
<DriveFolderName> ::= <String>
|
||||
<QueryDriveFile> :: = <String> See: https://developers.google.com/drive/api/v3/search-files
|
||||
<QueryDriveFile> :: = <String> See: https://developers.google.com/workspace/drive/api/guides/search-files
|
||||
<QuerySharedDrive> ::= <String> See: https://developers.google.com/workspace/drive/api/guides/search-shareddrives
|
||||
<DriveFileQueryEntity> ::=
|
||||
(query <QueryDriveFile>) | (query:<QueryDriveFile>)
|
||||
<DriveFileQueryShortcut> ::=
|
||||
@@ -90,15 +91,15 @@
|
||||
|
||||
<SharedDriveID> ::= <String>
|
||||
<SharedDriveName> ::= <String>
|
||||
<SharedDriveIDEntity> ::= (teamdriveid <SharedDriveID>) | (teamdriveid:<SharedDriveID>)
|
||||
<SharedDriveNameEntity> ::= (teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (teamdrivefilename <DriveFileName>) | (teamdrivefilename:<DriveFileName>)
|
||||
<SharedDriveIDEntity> ::= (shareddriveid <SharedDriveID>) | (shareddriveid:<SharedDriveID>)
|
||||
<SharedDriveNameEntity> ::= (shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (shareddrivefilename <DriveFileName>) | (shareddrivefilename:<DriveFileName>)
|
||||
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveIDEntity> |
|
||||
<SharedDriveNameEntity>
|
||||
<SharedDriveAdminQueryEntity> ::=
|
||||
(teamdriveadminquery <QueryTeamDrive>) | (teamdriveadminquery:<QueryTeamDrive>)
|
||||
(shareddriveadminquery <QuerySharedDrive>) | (shareddriveadminquery:<QuerySharedDrive>)
|
||||
<SharedDriveFileQueryEntity> ::=
|
||||
(query <QueryDriveFile>) | (query:<QueryDriveFile>)
|
||||
<SharedDriveFileQueryShortcut> ::=
|
||||
@@ -335,13 +336,13 @@ Select a Shared Drive file by giving its unique ID.
|
||||
```
|
||||
<SharedDriveIDEntity> ::=
|
||||
<DriveFileItem> |
|
||||
(teamdriveid <DriveFileItem>) | (teamdriveid:<DriveFileItem>)
|
||||
(shareddriveid <DriveFileItem>) | (shareddriveid:<DriveFileItem>)
|
||||
```
|
||||
### Examples
|
||||
```
|
||||
gam user testuser show fileinfo 1234ABCD
|
||||
gam user testuser show fileinfo id 1234ABCD
|
||||
gam user testuser show fileinfo teamdriveid 1234ABCD
|
||||
gam user testuser show fileinfo shareddriveid 1234ABCD
|
||||
```
|
||||
## Select Shared Drive file by name
|
||||
If you have the name, a search must be performed to find the ID that matches the name.
|
||||
@@ -350,16 +351,16 @@ You must specify the Shared Drive, either by ID or name, and the name of the fil
|
||||
Remember, searching for a file by name may return several file IDs if you have multiple files with the same name.
|
||||
```
|
||||
<SharedDriveIDEntity> ::=
|
||||
(teamdriveid <DriveFileItem>) | (teamdriveid:<DriveFileItem>)
|
||||
(shareddriveid <DriveFileItem>) | (shareddriveid:<DriveFileItem>)
|
||||
<SharedDriveNameEntity> ::=
|
||||
(teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
(shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::=
|
||||
(teamdrivefilename <DriveFileName>) | (teamdrivefilename:<DriveFileName>)
|
||||
(shareddrivefilename <DriveFileName>) | (shareddrivefilename:<DriveFileName>)
|
||||
```
|
||||
### Examples
|
||||
```
|
||||
gam user testuser show fileinfo teamdriveid 1234ABCD teamdrivefilename "Test File"
|
||||
gam user testuser show fileinfo teamdrive "Shared Drive 1" teamdrivefilename "Test File"
|
||||
gam user testuser show fileinfo shareddriveid 1234ABCD shareddrivefilename "Test File"
|
||||
gam user testuser show fileinfo shareddrive "Shared Drive 1" shareddrivefilename "Test File"
|
||||
```
|
||||
## Select Shared Drive file by query
|
||||
You can use a query to find a file ID. You perform the query on all Shared Drives or a specific Shared Drive.
|
||||
@@ -367,7 +368,7 @@ You can use a query to find a file ID. You perform the query on all Shared Drive
|
||||
See: [Drive Query](https://developers.google.com/drive/api/v3/search-files)
|
||||
```
|
||||
<SharedDriveFileQueryEntity> ::=
|
||||
(teamdrivequery <QueryDriveFile>) | (teamdrivequery:<QueryDriveFile>)
|
||||
(shareddrivequery <QueryDriveFile>) | (shareddrivequery:<QueryDriveFile>)
|
||||
<SharedDriveFileQueryShortcut> ::=
|
||||
all_files | all_folders | all_google_files | all_non_google_files | all_items
|
||||
```
|
||||
@@ -380,32 +381,32 @@ Keyword to query mappings for `<DriveFileQueryShortcut>`:
|
||||
|
||||
### Examples
|
||||
```
|
||||
gam user testuser show fileinfo teamdrivequery "name='Test File'"
|
||||
gam user testuser show fileinfo teamdriveid 1234ABCD teamdrivequery "name='Test File'"
|
||||
gam user testuser show fileinfo teamdrive teamdrive "Shared Drive 1" teamdrivequery "name='Test File'"
|
||||
gam user testuser show fileinfo teamdriveid 1234ABCD all_non_google_files
|
||||
gam user testuser show fileinfo shareddrivequery "name='Test File'"
|
||||
gam user testuser show fileinfo shareddriveid 1234ABCD shareddrivequery "name='Test File'"
|
||||
gam user testuser show fileinfo shareddrive shareddrive "Shared Drive 1" shareddrivequery "name='Test File'"
|
||||
gam user testuser show fileinfo shareddriveid 1234ABCD all_non_google_files
|
||||
```
|
||||
## Select root folder of a Shared Drive by ID
|
||||
The root folder of a Shared Drive is a folder, you select it by giving its unique ID.
|
||||
```
|
||||
<SharedDriveIDEntity> ::=
|
||||
<DriveFileItem> |
|
||||
(teamdriveid <DriveFileItem>) | (teamdriveid:<DriveFileItem>)
|
||||
(shareddriveid <DriveFileItem>) | (shareddriveid:<DriveFileItem>)
|
||||
```
|
||||
### Examples
|
||||
```
|
||||
gam user testuser show fileinfo 1234ABCD
|
||||
gam user testuser show fileinfo teamdriveid 1234ABCD
|
||||
gam user testuser show fileinfo shareddriveid 1234ABCD
|
||||
|
||||
```
|
||||
## Select root folder of a Shared Drive by name
|
||||
If you have a Shared Drive name, a search must be performed to find the ID that matches the name.
|
||||
```
|
||||
<SharedDriveNameEntity> ::=
|
||||
(teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
(shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
```
|
||||
### Examples
|
||||
```
|
||||
gam user testuser show fileinfo teamdrive "Shared Drive 1"
|
||||
gam user testuser show fileinfo shareddrive "Shared Drive 1"
|
||||
|
||||
```
|
||||
|
||||
@@ -27,13 +27,13 @@
|
||||
(anydrivefilename <DriveFileName>) | (anydrivefilename:<DriveFileName>)
|
||||
<SharedDriveIDEntity> ::=
|
||||
<DriveFileItem> |
|
||||
(teamdriveid <DriveFileItem>) | (teamdriveid:<DriveFileItem>)
|
||||
(shareddriveid <DriveFileItem>) | (shareddriveid:<DriveFileItem>)
|
||||
<SharedDriveName> ::= <String>
|
||||
<SharedDriveNameEntity> ::=
|
||||
(teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
(shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveIDEntity> |
|
||||
<SharedDriveNameEntity>
|
||||
<SharedDriveFileNameEntity> ::=
|
||||
(teamdrivefilename <DriveFileName>) | (teamdrivefilename:<DriveFileName>)
|
||||
(shareddrivefilename <DriveFileName>) | (shareddrivefilename:<DriveFileName>)
|
||||
```
|
||||
|
||||
@@ -10,6 +10,341 @@ Add the `-s` option to the end of the above commands to suppress creating the `g
|
||||
|
||||
See [Downloads-Installs-GAM7](https://github.com/GAM-team/GAM/wiki/Downloads-Installs) for Windows or other options, including manual installation
|
||||
|
||||
### 7.34.05
|
||||
|
||||
Updated `gam report <ActivityApplictionName>` to perform a reverse chronological sort
|
||||
on all rows across multiple users and/or event names; this is consistent with the behavior
|
||||
in the Admin console. Use option `notimesort` to suppress this sort.
|
||||
|
||||
### 7.34.04
|
||||
|
||||
Updated `gam <UserTypeEntity> create drivefileacl <DriveFileEntity> user <UserItem> role owner` to better
|
||||
handle the case where the current owner of a file is suspended. Previously, the command was displayed as an error
|
||||
even though the ownership was changed.
|
||||
```
|
||||
gam user currentowner@domain.com add drivefileacl <DriveFileID> user newowner@domain.com role owner
|
||||
User: currentowner@domain.com, Add 1 Drive File/Folder ACL
|
||||
User: currentowner@domain.com, Drive File/Folder ID: <DriveFileID>, Permission ID: newowner@domain.com, Add Failed: Sorry, the items were successfully shared but emails could not be sent to newowner@domain.com.
|
||||
```
|
||||
|
||||
Now the command is displayed as a success with a note indicating that the ownership change email was not sent.
|
||||
```
|
||||
gam user currentowner@domain.com add drivefileacl <DriveFileID> user newowner@domain.com role owner
|
||||
User: currentowner@domain.com, Add 1 Drive File/Folder ACL
|
||||
User: currentowner@domain.com, Drive File/Folder ID: <DriveFileID>, Permission ID: newowner@domain.com, Added: Sorry, the items were successfully shared but emails could not be sent to newowner@domain.com.
|
||||
New Owner
|
||||
id: 10834698115409747890
|
||||
type: user
|
||||
emailAddress: newowner@domain.com
|
||||
domain: domain.com
|
||||
role: owner
|
||||
permissionDetails:
|
||||
role: writer
|
||||
type: file
|
||||
inherited: True
|
||||
inheritedFrom: Unknown
|
||||
role: owner
|
||||
type: file
|
||||
inherited: False
|
||||
deleted: False
|
||||
pendingOwner: False
|
||||
```
|
||||
|
||||
### 7.34.03
|
||||
|
||||
Updated to Python 3.14.3
|
||||
|
||||
Updated Cryptography to 46.0.5
|
||||
|
||||
Updated `gam course <CourseID> create student|teacher <EmailAddress>` error message when
|
||||
`<EmailAddress>` is not in a trusted domain to remove suggestion about creating an invitation.
|
||||
|
||||
|
||||
### 7.34.02
|
||||
|
||||
Updated GAM to prevent errors like the following:
|
||||
```
|
||||
ERROR: Unable to find the server at oauth2.googleapis.com
|
||||
ERROR: Unable to find the server at gmail.googleapis.com
|
||||
```
|
||||
If you experience any unexpected errors, post a message to:
|
||||
* The GAM Discussion Forum (google-apps-manager@googlegroups.com)
|
||||
* The GAM Public Chat Room (https://chat.google.com/app/chat/AAAA4BULhWo)
|
||||
|
||||
### 7.34.01
|
||||
|
||||
Updated `gam create|update adminrole` to handle the following errors:
|
||||
```
|
||||
ERROR: 400: invalid - Invalid Role privileges
|
||||
ERROR: 400: required - Required parameter: [resource.privileges[n].service_id]
|
||||
```
|
||||
|
||||
### 7.34.00
|
||||
|
||||
Added variable `csv_output_header_required` to `gam.cfg` that is a comma separated list of `<Strings>`
|
||||
that are required to be in the list of column headers in the CSV file written by a gam print command.
|
||||
This will typically be used to specify headers that are required in subsequent commands that process
|
||||
the CSV file even if the API didn't return any data for those columns.
|
||||
|
||||
Updated the following commands to not require the `Directory API - Domains` scope
|
||||
unless the `internal` or `external` options are used to request the member category.
|
||||
```
|
||||
gam info|print groups
|
||||
gam print|show group-members
|
||||
gam info|print cigroups
|
||||
gam print|show cigroup-members
|
||||
gam <UserTypeEntity> print|show filesharecounts
|
||||
```
|
||||
|
||||
### 7.33.03
|
||||
|
||||
Fixed bug in `gam [<UserTypeEntity>] sendemail ... from <EmailAddress> replyto <EmailAddress>`
|
||||
where an `<EmailAddress>` of the form `Text <user@domain.com>` had the `Text` removed.
|
||||
|
||||
### 7.33.02
|
||||
|
||||
Added `hideinvitationssetting` to `<UserCalendarSettingsField>` used by
|
||||
`gam <UserTypeEntity> print|show calsettings`.
|
||||
|
||||
### 7.33.01
|
||||
|
||||
Added option `shownopolicy` to `gam print chromepolicies` that will display output like the following
|
||||
if no policies apply to the selected OU or group.
|
||||
```
|
||||
gam print chromepolicies ou /Test appid chrome:emidddocikgklceeeifefomdnbkldhng namespace chrome.users.apps shownopolicy
|
||||
Getting all Chrome Policies that match query (chrome.users.apps.*) for /Test
|
||||
Got 0 Chrome Policies that matched query (chrome.users.apps.*) for /Test...
|
||||
name,orgUnitPath,parentOrgUnitPath,direct,appId
|
||||
noPolicy,/Test,/,False,chrome:emidddocikgklceeeifefomdnbkldhng
|
||||
```
|
||||
|
||||
### 7.33.00
|
||||
|
||||
Added variable `developer_preview_apis` to `gam.cfg` that is a comma separated list of APIs requiring a Developer Preview key.
|
||||
Currently, `chat` is the only API that requires a Developer Preview key; it is required for the User Sections commands.
|
||||
* See: https://github.com/GAM-team/GAM/wiki/Users-Chat#introduction
|
||||
* See: https://github.com/GAM-team/GAM/wiki/Users-Chat#manage-chat-user-sections
|
||||
|
||||
### 7.32.07
|
||||
|
||||
Added option `includepermissionsforview published` to `gam <UserTypeEntity> print filelist` and
|
||||
`gam <UserTypeEntity> show fileinfo`. From the Drive API documentation:
|
||||
```
|
||||
Specifies which additional view's permissions to include in the response. Only published is supported.
|
||||
```
|
||||
|
||||
### 7.32.06
|
||||
|
||||
Added options to `gam <UserTypeEntity> copy drivefile ... copysubfiles` to limit copying
|
||||
to files whose `modifiedTime` meets specified requirements.
|
||||
* `start|starttime <Date>|<Time>` - If specified, `modifiedTime` must be >= the value
|
||||
* `end|endtime <Date>|<Time>` - If specified, `modifiedTime` must be <= the value
|
||||
* `range <Date>|<Time> <Date>|<Time>` - first value <= `modifiedTime` <= second value
|
||||
|
||||
### 7.32.05
|
||||
|
||||
Fixed bug in `gam <UserTypeEntity> print messages|threads ... headers <SMTPHeaderList>` where
|
||||
headers other than those specified in `<SMTPHeaderList>` were displayed.
|
||||
|
||||
Updated `gam info users <UserTypeEntity>` to display the following data when the Licensing API
|
||||
does not return data due to quota limits. Previously, no License data was displayed and
|
||||
there was no way to know if it was omitted due to API quota limits vs the user has no license?
|
||||
```
|
||||
Licenses: (1)
|
||||
Not available/incomplete
|
||||
```
|
||||
If a user has no licenses, this will be displayed.
|
||||
```
|
||||
Licenses: (0)
|
||||
```
|
||||
|
||||
You should use `license_skus = <SKUIDList>` in `gam.cfg` to list all of the licensing SKUs
|
||||
used in your workspace. Without this list, GAM has to make 70+ API calls to get the licenses
|
||||
for a user; this can cause quota limit errors.
|
||||
|
||||
### 7.32.04
|
||||
|
||||
Support for student groups in Google Classroom no longer requires Developer Preview membership.
|
||||
|
||||
Upgraded to OpenSSL 3.6.1.
|
||||
|
||||
### 7.32.03
|
||||
|
||||
Added option `template` as an additional formating option for `gam <UserTypeEntity> show signature`
|
||||
that displays just the HTML data; this simplifies capturing the data for use as input to GAM.
|
||||
```
|
||||
$ gam redirect stdout ./SigTemplate.html user user@domain.com show signature template
|
||||
$ more SigTemplate.html
|
||||
<div dir="ltr"><div dir="ltr"><div dir="ltr">
|
||||
<p style="margin:0px;font-size-adjust:none;font-stretch:normal;font-size:12px;line-height:normal;font-family:Monaco;color:rgb(0,0,0)">
|
||||
<span style="background-color:rgb(82,208,206)">{RT}Email: {Email}{/RT}</span></p>
|
||||
<p style="margin:0px;font-size-adjust:none;font-stretch:normal;font-size:12px;line-height:normal;font-family:Monaco;color:rgb(0,0,0)">
|
||||
<span style="background-color:rgb(82,208,206)">{RT}Phone: {Phone}{/RT}</span></p>
|
||||
<p style="margin:0px;font-size-adjust:none;font-stretch:normal;font-size:12px;line-height:normal;font-family:Monaco;color:rgb(0,0,0)">
|
||||
<span style="background-color:rgb(82,208,206)">{RT}Mobile: {Mobile}{/RT}</span></p>
|
||||
</div><br></div>\n</div>
|
||||
```
|
||||
|
||||
### 7.32.02
|
||||
|
||||
Added variable `oauth2_txt_lock_mode` to `gam.cfg`, the default is 644 and valid values are: 644, 664, 666.
|
||||
This value is used to set the file permissions on the `oauth2.txt.lock` file. In very special cases where
|
||||
daemon processes, e.g. Apache/httpd, are running GAM, the value 666 may have to be used.
|
||||
|
||||
### 7.32.01
|
||||
|
||||
Added option `(addcsvdata <FieldName> <String>)*` to `gam <CrOSTypeEntity> issuecommand command <CrOSCommand> csv`
|
||||
and `gam <CrOSTypeEntity> getcommand commandid <CommandID> csv` that adds additional columns of data to the CSV file output.
|
||||
* See: https://github.com/GAM-team/GAM/wiki/ChromeOS-Devices#bulk-action-example
|
||||
|
||||
### 7.32.00
|
||||
|
||||
Added option `verifyallowexternal` to `gam print cigroup-members|group-members` that causes
|
||||
GAM to only display external members in groups with `allowExternalMembers=False'.
|
||||
This option can be used to help verify that internal-only groups don't have external members.
|
||||
|
||||
Updated option `internaldomains` for the following commands:
|
||||
```
|
||||
gam info|print groups
|
||||
gam print|show group-members
|
||||
gam info|print cigroups
|
||||
gam print|show cigroup-members
|
||||
gam <UserTypeEntity> print|show filesharecounts
|
||||
```
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Added option `csv` to `gam <CrOSTypeEntity> issuecommand command <CrOSCommand>`
|
||||
and `gam <CrOSTypeEntity> getcommand commandid <CommandID>` so that command details are displayed in CSV format.
|
||||
This can be used to log commands issued to devices and then monitor the results.
|
||||
|
||||
Added option `filemimetype category <MimeTypeNameList>` to `gam <UserTypeEntity> copy drivefile` to support
|
||||
copying of files based on their MimeType category.
|
||||
|
||||
Added option `attendeeslist` to `gam calendars <CalendarEntity> print events` and `gam <UserTypeEntity> print events`
|
||||
that causes GAM to display the attendee email addresses in a single column `attendeesList`; no attendee details
|
||||
are displayed. The email addresses are separated by `csv_output_field_delimiter` from `gam.cfg`.
|
||||
|
||||
Fixed bug in `gam sendemail ... replyto <EmailAddress>` that caused a message delivery error if
|
||||
`<EmailAddress>` did not include a domain name.
|
||||
|
||||
Added support for users's chat sections.
|
||||
* See: https://github.com/GAM-team/GAM/wiki/Users-Chat#manage-chat-users-sections
|
||||
* This is in Deveoper Preview; you must have a `developer_preview_api_key` in `gam.cfg` to use these commands.
|
||||
|
||||
### 7.31.06
|
||||
|
||||
Added option `batchsize <Integer>` to `gam calendar <CalendarEntity> delete|purge events` and
|
||||
`gam <UserTypeEntity> delete|purge events <UserCalendarEntity>` that causes GAM to delete events
|
||||
with batch API calls rather than with individual API calls.
|
||||
|
||||
### 7.31.05
|
||||
|
||||
Added option `variables <RESearchPattern>` to `gam select section <SectionName> verify` and `gam config verify`
|
||||
that causes GAM to only display variables with names selected by `<RESearchPattern>`.
|
||||
```
|
||||
gam select School verify variables "^(customer|domain)"
|
||||
Section: School
|
||||
customer_id = C03abc123
|
||||
domain = school.edu
|
||||
|
||||
gam config verify variables 'dir'
|
||||
Section: DEFAULT
|
||||
cache_dir = ~/GamConfig/gamcache ; /Users/gamteam/GamConfig/gamcache
|
||||
config_dir = ~/GamConfig ; /Users/gamteam/GamConfig
|
||||
drive_dir = ~/GamWork ; /Users/gamteam/GamWork
|
||||
gmail_cse_incert_dir = ~/GmailCSE/Certs ; /Users/gamteam/GmailCSE/Certs
|
||||
gmail_cse_inkey_dir = ~/GmailCSE/Keys ; /Users/gamteam/GmailCSE/Keys
|
||||
input_dir = .
|
||||
```
|
||||
|
||||
### 7.31.04
|
||||
|
||||
Fixed bug in `gam report admin|chrome` that caused to events to not be displayed.
|
||||
|
||||
Updated `gam <UserTypeEntity> print|show messages|threads ... query <QueryGmail>` to display the query.
|
||||
|
||||
### 7.31.03
|
||||
|
||||
Due to the following Calendar API update, the `gam <UserTypeEntity> transfer calendars` command has been removed.
|
||||
* See: https://developers.google.com/workspace/calendar/release-notes#October_27_2025
|
||||
Data ownership can be transferred in the Google Calendar UI.
|
||||
|
||||
### 7.31.02
|
||||
|
||||
Added the following options to `gam <UserTypeEntity> copy drivefile`
|
||||
to limit copying to those files owned by selected users.
|
||||
* `copysubfilesownedby users <EmailAddressList>` - Only files owned by users in `<EmailAddressList>` are copied.
|
||||
* `copysubfilesownedby notusers <EmailAddressList>` - Only files not owned by users in `<EmailAddressList>` are copied.
|
||||
* `copysubfilesownedby regex <REMatchPattern>` - Only files owned by users whose email addresses match `<REMatchPattern>` are copied.
|
||||
* `copysubfilesownedby notregex <REMatchPattern>` - Only files owned by users whose email addresses do not match `<REMatchPattern>` are copied.
|
||||
|
||||
### 7.31.01
|
||||
|
||||
Code cleanup for `addcsvdata <FieldName> <String>`.
|
||||
|
||||
### 7.31.00
|
||||
|
||||
Fixed bug in `gam report chrome (user <UserItem>)|(select <UserTypeEntity>)` where no activities were returned.
|
||||
`report chrome` does not use the parameter `userKey=<EmailAddress>` as do other applications but requires
|
||||
parameter `filter DEVICE_USER==<EmailAddress>`.
|
||||
|
||||
Updated `gam report admin (user <UserItem>)|(select <UserTypeEntity>)` to use parameter `filter USER_EMAIL==<EmailAddress>`
|
||||
to display activiities affecting the user `<EmailAddress>`. Use option `userisactor` to use the parameter `userKey=<EmailAddress>`
|
||||
that displays activities where user `<EmailAddress>` executed the command that generated the activity.
|
||||
|
||||
Fixed bug in `gam print cros|filelist|users ... (addcsvdata <FieldName> <String>)+ formatjson` where the `addcsvdata` columns
|
||||
were not displayed but the additional field values were included in the JSON data. Now, the `addcsvdata` columns
|
||||
are displayed but the additional field values are only included in the JSON data when option `includdecsvdatainjson` is specified.
|
||||
|
||||
Added option `addcsvdata <FieldName> <String>` to `gam <UserTypeEntity> print cigroups|groups`
|
||||
that adds additional columns of data to the CSV file output.
|
||||
|
||||
Added option `addcsvdata <FieldName> <String>` to `gam <UserTypeEntity> print cigroupmembere|group-members`
|
||||
that adds additional columns of data to the CSV file output.
|
||||
|
||||
### 7.30.05
|
||||
|
||||
Added option `gmaileventtypes <NumberRangeList>` to `gam report gmail` that can be used to limit the event types displayed.
|
||||
```
|
||||
<NumberRange> ::= <Number>|(<Number>/<Number>)
|
||||
<NumberRangeList> ::= "<NumberRange>(,<NumberRange>)*"
|
||||
|
||||
gam report gmail user user@domain.com gmaileventtypes 1,10/11
|
||||
```
|
||||
* See: https://developers.google.com/workspace/admin/reports/v1/appendix/activity/gmail
|
||||
|
||||
Updated sorting of column headers in `gam report <ActivityApplicationName>`.
|
||||
|
||||
### 7.30.04
|
||||
|
||||
Updated `gam report gmail` to avoid the following error when incomplete start/end time information is provided.
|
||||
```
|
||||
ERROR: Invalid request: Start time and end time should both be provided, and the scan duration should not be greater than 30 days.
|
||||
```
|
||||
* No time information provided - GAM sets `range -30d today`
|
||||
* Only `start <Time>` provided - GAM sets `end <Time>+30d`
|
||||
* Only `end <Time>` provided - GAM sets `start <Time>-30d`
|
||||
|
||||
### 7.30.03
|
||||
|
||||
Updated `gam report <ActivityApplicationName>` to reflect the changes described here:
|
||||
* See: https://workspaceupdates.googleblog.com/2025/12/google-workspace-audit-log-api.html
|
||||
|
||||
Added option `resourcedetailsfilter <String>` to `gam report <ActivityApplicationName>` described here:
|
||||
* See: https://developers.google.com/workspace/admin/reports/reference/rest/v1/activities/list#query-parameters
|
||||
|
||||
For `gam <UserTypeEntity> print <Objects>`, expanded the list of `<Objects>` covered by `gam.cfg csv_output_users_audit = True`.
|
||||
|
||||
### 7.30.02
|
||||
|
||||
Added option `conferencedata meet <MeetID>` to `<EventAttribute>` that allows specifying
|
||||
a reference to an existing Google Meet when creating/updating a calendar event.
|
||||
|
||||
Upgraded to Python 3.14.2.
|
||||
|
||||
### 7.30.01
|
||||
|
||||
Fixed bug introduced in 7.30.00 that caused errors when reading CSV files.
|
||||
@@ -2814,7 +3149,7 @@ Added option `showmimetype category <MimeTypeNameList>` to `gam <UserTypeEntity>
|
||||
<MimeTypeName> ::= application|audio|font|image|message|model|multipart|text|video
|
||||
<MimeTypeNameList> ::= "<MimeTypeName>(,<MimeTypeName>)*"
|
||||
|
||||
gam user user@domain.com print filelist fields id,name,mimetype showmimetype prefixes audio,video
|
||||
gam user user@domain.com print filelist fields id,name,mimetype showmimetype category audio,video
|
||||
```
|
||||
|
||||
### 6.71.11
|
||||
|
||||
@@ -615,7 +615,7 @@ gam print group-members [todrive <ToDriveAttribute>*]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[admincreatedmatch <Boolean>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[membernames] [showdeliverysettings]
|
||||
<MembersFieldName>* [fields <MembersFieldNameList>]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
@@ -626,6 +626,7 @@ gam print group-members [todrive <ToDriveAttribute>*]
|
||||
[(recursive [noduplicates])|includederivedmembership] [nogroupemail]
|
||||
[peoplelookup|(peoplelookupuser <EmailAddress>)]
|
||||
[unknownname <String>] [cachememberinfo [Boolean]]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, the group membership of all groups in the account are displayed, these options allow selection of subsets of groups:
|
||||
@@ -681,13 +682,21 @@ By default, when displaying members from a group, all members, whether suspended
|
||||
* `notsuspended archived` - Only include archived members, this is not common but allows creating groups that allow easy identification of archived users
|
||||
* `suspended notarchived` - Only include suspended members, this is not common but allows creating groups that allow easy identification of suspended users
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered internal.
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered `internal`.
|
||||
|
||||
When the `internal` or `external` options are specified, GAM adds the column `allowExternalMembers`
|
||||
that shows that setting for the group and adds the column `category` that shows whether the member
|
||||
is `external` or `internal`.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
@@ -733,6 +742,9 @@ The options `recursive noduplicates` and `includederivedmembership types user no
|
||||
The `includederivedmembership` option makes less API calls but doesn't show level and subgroup information.
|
||||
Expanding a member of type CUSTOMER may produce a large volume of data as it will display all users in your domain.
|
||||
|
||||
Add additional columns of data from the command line to the output
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
@@ -752,7 +764,7 @@ gam show group-members
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[admincreatedmatch <Boolean>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners] [depth <Number>]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
[types <GroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
@@ -805,232 +817,17 @@ By default, when displaying members from a group, all members, whether suspended
|
||||
By default, all types of members (customer, group, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <GroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered internal.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
* `memberemailskippattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will not be displayed; others will be displayed
|
||||
|
||||
By default, members of type GROUP are recursively expanded to show their constituent members. (Members of
|
||||
type CUSTOMER are not expanded.) The `depth <Number>` argument controls the depth to which nested groups are displayed.
|
||||
* `depth -1` - all groups in the selected group and below are displayed; this is the default.
|
||||
* `depth 0` - the groups within a selected group are displayed, no descendants are displayed.
|
||||
* `depth N` - the groups within the selected group and those groups N levels below the selected group are displayed.
|
||||
|
||||
The `includederivedmembership` option causes the API to expand type GROUP and type CUSTOMER
|
||||
members to display their constituent members while still displaying the original member.
|
||||
|
||||
The options `types user` and `includederivedmembership types user` return the same list of users.
|
||||
The `includederivedmembership` option makes less API calls but doesn't show hierarchy.
|
||||
Expanding a member of type CUSTOMER may produce a large volume of data as it will display all users in your domain.
|
||||
|
||||
### Display group structure
|
||||
To see a group's structure of nested groups use the `type group` option.
|
||||
```
|
||||
$ gam show group-members group testgroup5 types group
|
||||
Group: testgroup5@domain.com
|
||||
MEMBER, GROUP, testgroup1@domain.com, ACTIVE
|
||||
MEMBER, GROUP, testgroup2@domain.com, ACTIVE
|
||||
MEMBER, GROUP, testgroup3@domain.com, ACTIVE
|
||||
MEMBER, GROUP, testgroup2@domain.com, ACTIVE
|
||||
MEMBER, GROUP, testgroup4@domain.com, ACTIVE
|
||||
```
|
||||
To show the structure of all groups you can do the following; it will be time consuming for a large number of groups.
|
||||
```
|
||||
gam redirect stdout ./groups.txt show group-members types group
|
||||
```
|
||||
|
||||
### Examples
|
||||
#### Print a CSV of all members of a group regardless of role, all fields
|
||||
```
|
||||
gam print group-members <GroupEntity>
|
||||
```
|
||||
#### Print a CSV containing all managers emails
|
||||
```
|
||||
gam print group-members <GroupEntity> role manager fields email
|
||||
```
|
||||
#### Print a CSV output of all members and their emails only
|
||||
```
|
||||
gam print group-members <GroupEntity> role member fields email
|
||||
```
|
||||
#### Display group owners in your domain, but excluding groups where the email starts with a 4 digit code
|
||||
```
|
||||
gam print group-members domain <Your Domain> emailmatchpattern not '^1234.*' roles owners
|
||||
```
|
||||
|
||||
|
||||
These options further limit the list of groups selected above:
|
||||
* `emailmatchpattern <REMatchPattern>` - Limit display to groups whose email address matches `<REMatchPattern>`
|
||||
* `emailmatchpattern not <REMatchPattern>` - Limit display to groups whose email address does not match `<REMatchPattern>`
|
||||
* `namematchpattern <REMatchPattern>` - Limit display to groups whose name matches `<REMatchPattern>`
|
||||
* `namematchpattern not <REMatchPattern>` - Limit display to groups whose name does not match `<REMatchPattern>`
|
||||
* `descriptionmatchpattern <REMatchPattern>` - Limit display to groups whose description matches `<REMatchPattern>`
|
||||
* `descriptionmatchpattern not <REMatchPattern>` - Limit display to groups whose description does not match `<REMatchPattern>`
|
||||
* `admincreatedmatch True` - Limit display to groups created by administrators
|
||||
* `admincreatedmatch False` - Limit display to groups created by users
|
||||
|
||||
By default, all members, managers and owners in the group are displayed; these options modify that behavior:
|
||||
* `roles <GroupRoleList>` - Display specified roles
|
||||
* `members` - Display members
|
||||
* `managers` - Display managers
|
||||
* `owners` - Display owners
|
||||
|
||||
By default, all types of members (customer, group, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <GroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, members that are groups are displayed as a single entry of type GROUP; this option recursively expands group members to display their user members.
|
||||
* `recursive` - Recursively expand group members
|
||||
|
||||
When `recursive` is specified, the default is to only display type user members; this option modifies those behaviors:
|
||||
* `types <GroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, when displaying members from a group, all members, whether suspended/archived or not, are included.
|
||||
* `notsuspended` - Display only non-suspended members
|
||||
* `suspended` - Display only suspended members
|
||||
* `notarchived` - Do not include archived members
|
||||
* `archived` - Only include archived members, this is not common but allows creating groups that allow easy identification of archived users
|
||||
* `notsuspended notarchived` - Do not include suspended and archived members
|
||||
* `suspended archived` - Include only suspended or archived members
|
||||
* `notsuspended archived` - Only include archived members, this is not common but allows creating groups that allow easy identification of archived users
|
||||
* `suspended notarchived` - Only include suspended members, this is not common but allows creating groups that allow easy identification of suspended users
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered internal.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
* `memberemailskippattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will not be displayed; others will be displayed
|
||||
|
||||
By default, the ID, role, email address, type and status of each member are displayed along with the group email address;
|
||||
these options specify which fields to display:
|
||||
* `membernames` - Display members full name; an additional API call per member is required
|
||||
* `showdeliverysettings` - Display delivery settings; an additional API call per member is required
|
||||
* `<MembersFieldName>*` - Individual field names
|
||||
* `fields <MembersFieldNameList>` - A comma separated list of field names
|
||||
* `delivery|deliverysettings` - Specify this field to get delivery information; an additional API call per member is required
|
||||
|
||||
For members that are users, you can specify additional information to display; an additional API call per member is required
|
||||
* `userfields <UserFieldNameList>` - Display specific user fields
|
||||
* `allschemas|(schemas|custom|customschemas <SchemaNameList>)` - Display all or specific custom schema values
|
||||
|
||||
The additional API calls can be reduced with the `cachememberinfo` option; a single API call is made for each user/group
|
||||
and the data is cached to eliminate to need to repeat the API call; this consumes more memory but dramatically reduces the number of API calls.
|
||||
|
||||
If member names are requested, names are not available for users not in the domain; you can request that GAM use the People API to retrieve
|
||||
names for these users. Names are not retrieved in all cases and success is dependent on what user is used to perform the retrievals.
|
||||
* `peoplelookup` - Use the administrator named in oauth2.txt to perform the retrievals
|
||||
* `peoplelookupuser <EmailAddress>` - Use `<EmailAddress>` to perform the retrievals
|
||||
|
||||
By default, when `membernames` is specified, GAM displays `Unknown` for members whose names can not be determined.
|
||||
Use `unknownname <String>` to specify an alternative value.
|
||||
|
||||
By default, the group email address is always shown, you can suppress it with the `nogroupemail` option.
|
||||
|
||||
The `recursive` option adds two columns, level and subgroup, to the output:
|
||||
* `level` - At what level of the expansion does the user appear; level 0 is the top level
|
||||
* `subgroup` - The group that contained the user
|
||||
|
||||
Displaying membership of multiple groups or recursive expansion may result in multiple instances of the same user being displayed; these multiple instances can be reduced to one entry.
|
||||
* `noduplicates` - Reduce multiple instances of the same user to the first instance
|
||||
|
||||
The `includederivedmembership` option is an alternative to `recursive`; it causes the API to expand type GROUP and type CUSTOMER
|
||||
members to display their constituent members while still displaying the original member.
|
||||
The API produces inconsistent results, use with caution.
|
||||
|
||||
The options `recursive noduplicates` and `includederivedmembership types user noduplicates` return the same list of users.
|
||||
The `includederivedmembership` option makes less API calls but doesn't show level and subgroup information.
|
||||
Expanding a member of type CUSTOMER may produce a large volume of data as it will display all users in your domain.
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
The `quotechar <Character>` option allows you to choose an alternate quote character, single quote for instance, that makes for readable/processable output.
|
||||
`quotechar` defaults to `gam.cfg/csv_output_quote_char`. When uploading CSV files to Google, double quote `"` should be used.
|
||||
|
||||
## Display group membership in hierarchical format
|
||||
```
|
||||
gam show group-members
|
||||
[([domain|domains <DomainNameEntity>] ([member|showownedby <EmailItem>]|[(query <QueryGroup>)|(queries <QueryGroupList>)]))|
|
||||
(group|group_ns|group_susp <GroupItem>)|
|
||||
(select <GroupEntity>)]
|
||||
[emailmatchpattern [not] <REMatchPattern>] [namematchpattern [not] <REMatchPattern>]
|
||||
[descriptionmatchpattern [not] <REMatchPattern>]
|
||||
[admincreatedmatch <Boolean>]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners] [depth <Number>]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
[types <GroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[includederivedmembership]
|
||||
```
|
||||
By default, the group membership of all groups in the account are displayed, these options allow selection of subsets of groups:
|
||||
* `domain|domains <DomainNameEntity>` - Limit display to groups in the domains specified by `<DomainNameEntity>`
|
||||
* You can predefine this list with the `print_agu_domains` variable in `gam.cfg`.
|
||||
* `member <EmailItem>` - Limit display to groups that contain `<EmailItem>` as a member; mutually exclusive with `query <QueryGroup>`
|
||||
* `showownedby <EmailItem>` - Limit display to groups that contain `<EmailItem>` as an owner; mutually exclusive with `query <QueryGroup>`
|
||||
* `(query <QueryGroup>)|(queries <QueryGroupList>)` - Limit groups to those that match a query; each query is run against each domain
|
||||
* `group <GroupItem>` - Limit display to the single group `<GroupItem>`
|
||||
* `group_ns <GroupItem>` - Limit display to the single group `<GroupItem>`, display non-suspended members
|
||||
* `group_susp <GroupItem>` - Limit display to the single group `<GroupItem>`, display suspended members
|
||||
* `select <GroupEntity>` - Limit display to the groups specified in `<GroupEntity>`
|
||||
* `showownedby <UserItem>` - Limit display to groups owned by `<UserItem>`
|
||||
|
||||
When using `query <QueryGroup>` with the `name:{PREFIX}*` query, `PREFIX` must contain at least three characters.
|
||||
|
||||
You can identify groups with the `All users in the organization` member with:
|
||||
* `query "memberKey=<CustomerID>"`
|
||||
* `member id:<CustomerID>`
|
||||
|
||||
These options further limit the list of groups selected above:
|
||||
* `emailmatchpattern <REMatchPattern>` - Limit display to groups whose email address matches `<REMatchPattern>`
|
||||
* `emailmatchpattern not <REMatchPattern>` - Limit display to groups whose email address does not match `<REMatchPattern>`
|
||||
* `namematchpattern <REMatchPattern>` - Limit display to groups whose name matches `<REMatchPattern>`
|
||||
* `namematchpattern not <REMatchPattern>` - Limit display to groups whose name does not match `<REMatchPattern>`
|
||||
* `descriptionmatchpattern <REMatchPattern>` - Limit display to groups whose description matches `<REMatchPattern>`
|
||||
* `descriptionmatchpattern not <REMatchPattern>` - Limit display to groups whose description does not match `<REMatchPattern>`
|
||||
* `admincreatedmatch True` - Limit display to groups created by administrators
|
||||
* `admincreatedmatch False` - Limit display to groups created by users
|
||||
|
||||
By default, all members, managers and owners in the group are displayed; these options modify that behavior:
|
||||
* `roles <GroupRoleList>` - Display specified roles
|
||||
* `members` - Display members
|
||||
* `managers` - Display managers
|
||||
* `owners` - Display owners
|
||||
|
||||
By default, when displaying members from a group, all members, whether suspended/archived or not, are included.
|
||||
* `notsuspended` - Display only non-suspended members
|
||||
* `suspended` - Display only suspended members
|
||||
* `notarchived` - Do not include archived members
|
||||
* `archived` - Only include archived members, this is not common but allows creating groups that allow easy identification of archived users
|
||||
* `notsuspended notarchived` - Do not include suspended and archived members
|
||||
* `suspended archived` - Include only suspended or archived members
|
||||
* `notsuspended archived` - Only include archived members, this is not common but allows creating groups that allow easy identification of archived users
|
||||
* `suspended notarchived` - Only include suspended members, this is not common but allows creating groups that allow easy identification of suspended users
|
||||
|
||||
By default, all types of members (customer, group, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <GroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered internal.
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered `internal`.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
|
||||
@@ -396,7 +396,7 @@ gam info group|groups <GroupEntity>
|
||||
[basic] <GroupFieldName>* [fields <GroupFieldNameList>] [nodeprecated]
|
||||
[ciallfields|(cifields <CIGroupFieldNameList>)]
|
||||
[roles <GroupRoleList>] [members] [managers] [owners]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains All|<DomainNameList>] [external]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
[types <GroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
@@ -423,13 +423,17 @@ By default, when displaying members from a group, all members, whether suspended
|
||||
By default, when displaying members from a group, all types of members (customer, group, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <GroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your primary workspace domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered internal.
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered `internal`.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
@@ -467,13 +471,14 @@ gam print groups [todrive <ToDriveAttribute>*]
|
||||
[ciallfields|(cifields <CIGroupFieldNameList>)]
|
||||
[nodeprecated]
|
||||
[roles <GroupRoleList>]
|
||||
[internal] [internaldomains <DomainNameList>] [external]
|
||||
[internal] [internaldomains all|primary|<DomainNameList>] [external]
|
||||
[members|memberscount] [managers|managerscount] [owners|ownerscount] [totalcount] [countsonly]
|
||||
[includederivedmembership]
|
||||
[notsuspended|suspended] [notarchived|archived]
|
||||
[types <GroupMemberTypeList>]
|
||||
[memberemaildisplaypattern|memberemailskippattern <REMatchPattern>]
|
||||
[convertcrnl] [delimiter <Character>] [sortheaders]
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, all groups in the account are displayed, these options allow selection of subsets of groups:
|
||||
@@ -557,21 +562,34 @@ By default, when displaying members from a group, all members, whether suspended
|
||||
By default, when displaying members from a group, all types of members (customer, group, user) in the group are displayed; this option modifies that behavior:
|
||||
* `types <GroupMemberTypeList>` - Display specified types
|
||||
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal internaldomains <DomainNameList>` - Display members whose domain is in `<DomainNameList>`
|
||||
* `external internaldomains <DomainNameList>` - Display members whose domain is not in `<DomainNameList>`
|
||||
* `internal external internaldomains <DomainNameList>` - Display all members, indicate their category: internal or external
|
||||
* `internaldomains <DomainNameList>` - Defaults to value of `domain` in `gam.cfg`
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered internal.
|
||||
By default, when listing group members, GAM does not take the domain of the member into account.
|
||||
* `internal` - Display members whose domain matches a value in `internaldomains`
|
||||
* `external` - Display members whose domain does not match value in `internaldomains`
|
||||
* `internal external` - Display all members, indicate their category: `internal` or `external`
|
||||
|
||||
Members without an email address, e.g. `customer`, are considered `internal`.
|
||||
|
||||
When the `internal` or `external` options are specified, GAM adds the column `allowExternalMembers`
|
||||
that shows that setting for the group.
|
||||
|
||||
Members that have met the above qualifications to be displayed can be further qualifed by their email address.
|
||||
* `memberemaildisplaypattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will be displayed; others will not be displayed
|
||||
* `memberemailskippattern <REMatchPattern>` - Members with email addresses that match `<REMatchPattern>` will not be displayed; others will be displayed
|
||||
|
||||
Add additional columns of data from the command line to the output
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
If `formatjson` and `addcsvdata` are specified, the option `includecsvdatainjson` causes GAM to add the
|
||||
additional field values to the JSON data.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
|
||||
31
wiki/Home.md
31
wiki/Home.md
@@ -10,7 +10,36 @@ To run all commands properly, GAM7 requires three things:
|
||||
* A special service account that is authorized to act on behalf of your users in order to modify user-specific settings and data such as Drive files, Calendars and Gmail messages and settings like signatures.
|
||||
|
||||
# Documentation
|
||||
See the sections in the right-hand column for documentation.
|
||||
|
||||
## Update History
|
||||
A log of updates to GAM7.
|
||||
|
||||
## Installation
|
||||
Instructions detailing ways of installing GAM7 and alternate installation issues.
|
||||
|
||||
## Configuration
|
||||
Instructions detailing configuration of GAM7 and alternate authorization methods.
|
||||
|
||||
## Notes and Information
|
||||
References to resources that enhance your use of GAM7.
|
||||
|
||||
## Definitions
|
||||
BNF definitions of common items in the GAM7 command syntax.
|
||||
|
||||
## Command Processing
|
||||
Information regarding use of command line options to control how GAM7 operates.
|
||||
|
||||
## Collections
|
||||
BNF Syntax definitions of ways to specify multiple Googlw Workspace opjects.
|
||||
|
||||
## Client Access
|
||||
Syntax, descriptions and examples of commands that are executed by your Google Workspace administrator.
|
||||
|
||||
## Special Service Account Access
|
||||
How to set up a GAM7 Chat Bot; this is required to use the Chat API to manage Chat Spaces in your Google Workspace.
|
||||
|
||||
## Service Account Access
|
||||
Syntax, descriptions and examples of commands that are executed on behalf of your Google Workspace users.
|
||||
|
||||
# Installation
|
||||
* [How to Install GAM7](How-to-Install-GAM7)
|
||||
|
||||
@@ -9,30 +9,30 @@ and all necessary authentications.
|
||||
|
||||
## Linux and MacOS and Google Cloud Shell
|
||||
|
||||
In these examples, your Google Super admin is shown as admin@domain.com; replace with the
|
||||
In these examples, your Google Super admin is shown as gamteam@domain.com; replace with the
|
||||
actual email adddress.
|
||||
|
||||
In these examples, the user home folder is shown as /Users/admin; adjust according to your
|
||||
In these examples, the user home folder is shown as /Users/gamteam; adjust according to your
|
||||
specific situation; e.g., /home/administrator.
|
||||
|
||||
This example assumes that GAM7 has been installed in /Users/admin/bin/gam7.
|
||||
This example assumes that GAM7 has been installed in /Users/gamteam/bin/gam7.
|
||||
If you've installed GAM7 in another directory, substitute that value in the directions.
|
||||
|
||||
### Set a configuration directory
|
||||
|
||||
The default GAM configuration directory is /Users/admin/.gam; for more flexibility you
|
||||
The default GAM configuration directory is /Users/gamteam/.gam; for more flexibility you
|
||||
probably want to select a non-hidden location. This example assumes that the GAM
|
||||
configuration directory will be /Users/admin/GAMConfig; If you've chosen another directory,
|
||||
configuration directory will be /Users/gamteam/GAMConfig; If you've chosen another directory,
|
||||
substitute that value in the directions.
|
||||
|
||||
Make the directory:
|
||||
```
|
||||
admin@server:/Users/admin$ mkdir -p /Users/admin/GAMConfig
|
||||
gamteam@server:/Users/gamteam$ mkdir -p /Users/gamteam/GAMConfig
|
||||
```
|
||||
|
||||
Add the following line:
|
||||
```
|
||||
export GAMCFGDIR="/Users/admin/GAMConfig"
|
||||
export GAMCFGDIR="/Users/gamteam/GAMConfig"
|
||||
```
|
||||
to one of these files based on your shell:
|
||||
```
|
||||
@@ -44,34 +44,34 @@ to one of these files based on your shell:
|
||||
|
||||
Issue the following command replacing `<Filename>` with the name of the file you edited:
|
||||
```
|
||||
admin@server:/Users/admin$ source <Filename>
|
||||
gamteam@server:/Users/gamteam$ source <Filename>
|
||||
```
|
||||
|
||||
You need to make sure the GAM configuration directory actually exists. Test that like this:
|
||||
```
|
||||
admin@server:/Users/admin$ ls -l $GAMCFGDIR
|
||||
gamteam@server:/Users/gamteam$ ls -l $GAMCFGDIR
|
||||
```
|
||||
|
||||
### Set a working directory
|
||||
|
||||
You should establish a GAM working directory; you will store your GAM related
|
||||
data in this folder and execute GAM commands from this folder. You should not use
|
||||
/Users/admin/bin/gam7 or /Users/admin/GAMConfig for this purpose.
|
||||
This example assumes that the GAM working directory will be /Users/admin/GAMWork; If you've chosen
|
||||
/Users/gamteam/bin/gam7 or /Users/gamteam/GAMConfig for this purpose.
|
||||
This example assumes that the GAM working directory will be /Users/gamteam/GAMWork; If you've chosen
|
||||
another directory, substitute that value in the directions.
|
||||
|
||||
Make the directory:
|
||||
```
|
||||
admin@server:/Users/admin$ mkdir -p /Users/admin/GAMWork
|
||||
gamteam@server:/Users/gamteam$ mkdir -p /Users/gamteam/GAMWork
|
||||
```
|
||||
|
||||
### Set an alias
|
||||
You should set an alias to point to /Users/admin/bin/gam7/gam so you can operate from the /Users/admin/GAMWork directory.
|
||||
You should set an alias to point to /Users/gamteam/bin/gam7/gam so you can operate from the /Users/gamteam/GAMWork directory.
|
||||
Aliases aren't available in scripts, so you may want to set a symlink instead, see below.
|
||||
|
||||
Add the following line:
|
||||
```
|
||||
alias gam="/Users/admin/bin/gam7/gam"
|
||||
alias gam="/Users/gamteam/bin/gam7/gam"
|
||||
```
|
||||
to one of these files based on your shell:
|
||||
```
|
||||
@@ -84,48 +84,48 @@ to one of these files based on your shell:
|
||||
|
||||
Issue the following command replacing `<Filename>` with the name of the file you edited:
|
||||
```
|
||||
admin@server:/Users/admin$ source <Filename>
|
||||
gamteam@server:/Users/gamteam$ source <Filename>
|
||||
```
|
||||
|
||||
### Set a symlink
|
||||
Set a symlink in `/usr/local/bin` (or some other location on $PATH) to point to GAM.
|
||||
```
|
||||
admin@server:/Users/admin$ ln -s "/Users/admin/bin/gam7/gam" /usr/local/bin/gam
|
||||
gamteam@server:/Users/gamteam$ ln -s "/Users/gamteam/bin/gam7/gam" /usr/local/bin/gam
|
||||
```
|
||||
|
||||
### Initialize GAM7; this should be the first GAM7 command executed.
|
||||
```
|
||||
admin@server:/Users/admin$ gam config drive_dir /Users/admin/GAMWork verify
|
||||
Created: /Users/admin/GAMConfig
|
||||
Created: /Users/admin/GAMConfig/gamcache
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Initialized
|
||||
gamteam@server:/Users/gamteam$ gam config drive_dir /Users/gamteam/GAMWork verify
|
||||
Created: /Users/gamteam/GAMConfig
|
||||
Created: /Users/gamteam/GAMConfig/gamcache
|
||||
Config File: /Users/gamteam/GAMConfig/gam.cfg, Initialized
|
||||
Section: DEFAULT
|
||||
...
|
||||
cache_dir = /Users/admin/GAMConfig/gamcache
|
||||
cache_dir = /Users/gamteam/GAMConfig/gamcache
|
||||
...
|
||||
config_dir = /Users/admin/GAMConfig
|
||||
config_dir = /Users/gamteam/GAMConfig
|
||||
...
|
||||
drive_dir = /Users/admin/GAMWork
|
||||
drive_dir = /Users/gamteam/GAMWork
|
||||
...
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Verify initialization, this was a successful installation.
|
||||
```
|
||||
admin@server:/Users/admin$ ls -l $GAMCFGDIR
|
||||
gamteam@server:/Users/gamteam$ ls -l $GAMCFGDIR
|
||||
total 48
|
||||
-rw-r-----+ 1 admin staff 1069 Mar 3 09:23 gam.cfg
|
||||
drwxr-x---+ 2 admin staff 68 Mar 3 09:23 gamcache
|
||||
-rw-rw-rw-+ 1 admin staff 0 Mar 3 09:23 oauth2.txt.lock
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Create your project with local browser
|
||||
```
|
||||
admin@server:/Users/admin$ gam create project
|
||||
WARNING: Config File: /Users/admin/GAMConfig/gam.cfg, Item: client_secrets_json, Value: /Users/admin/GAMConfig/client_secrets.json, Not Found
|
||||
WARNING: Config File: /Users/admin/GAMConfig/gam.cfg, Item: oauth2service_json, Value: /Users/admin/GAMConfig/oauth2service.json, Not Found
|
||||
gamteam@server:/Users/gamteam$ gam create project
|
||||
WARNING: Config File: /Users/gamteam/GAMConfig/gam.cfg, Item: client_secrets_json, Value: /Users/gamteam/GAMConfig/client_secrets.json, Not Found
|
||||
WARNING: Config File: /Users/gamteam/GAMConfig/gam.cfg, Item: oauth2service_json, Value: /Users/gamteam/GAMConfig/oauth2service.json, Not Found
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gamteam@domain.com
|
||||
|
||||
Your browser has been opened to visit:
|
||||
|
||||
@@ -167,7 +167,7 @@ Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-p
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Extracting public certificate
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Done generating private key and public certificate
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Service Account Key: SVCACCTKEY, Uploaded
|
||||
Service Account OAuth2 File: /Users/admin/GAMConfig/oauth2service.json, Service Account Key: SVCACCTKEY, Updated
|
||||
Service Account OAuth2 File: /Users/gamteam/GAMConfig/oauth2service.json, Service Account Key: SVCACCTKEY, Updated
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Has rights to rotate own private key
|
||||
Please go to:
|
||||
|
||||
@@ -185,16 +185,16 @@ Enter your Client Secret: CLIENTSECRET
|
||||
6. Go back to your browser and click OK to close the "OAuth client" popup if it's still open.
|
||||
That's it! Your GAM Project is created and ready to use.
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Create your project without local browser (Google Cloud Shell for instance)
|
||||
```
|
||||
admin@server:/Users/admin$ gam config no_browser true save
|
||||
admin@server:/Users/admin$ gam create project
|
||||
WARNING: Config File: /Users/admin/GAMConfig/gam.cfg, Item: client_secrets_json, Value: /Users/admin/GAMConfig/client_secrets.json, Not Found
|
||||
WARNING: Config File: /Users/admin/GAMConfig/gam.cfg, Item: oauth2service_json, Value: /Users/admin/GAMConfig/oauth2service.json, Not Found
|
||||
gamteam@server:/Users/gamteam$ gam config no_browser true save
|
||||
gamteam@server:/Users/gamteam$ gam create project
|
||||
WARNING: Config File: /Users/gamteam/GAMConfig/gam.cfg, Item: client_secrets_json, Value: /Users/gamteam/GAMConfig/client_secrets.json, Not Found
|
||||
WARNING: Config File: /Users/gamteam/GAMConfig/gam.cfg, Item: oauth2service_json, Value: /Users/gamteam/GAMConfig/oauth2service.json, Not Found
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on other computer:
|
||||
|
||||
@@ -235,7 +235,7 @@ Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-p
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Extracting public certificate
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Done generating private key and public certificate
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Service Account Key: SVCACCTKEY, Uploaded
|
||||
Service Account OAuth2 File: /Users/admin/GAMConfig/oauth2service.json, Service Account Key: SVCACCTKEY, Updated
|
||||
Service Account OAuth2 File: /Users/gamteam/GAMConfig/oauth2service.json, Service Account Key: SVCACCTKEY, Updated
|
||||
Project: gam-project-abc-def-ghi, Service Account: gam-project-abc-def-ghi@gam-project-abc-def-ghi.iam.gserviceaccount.com, Has rights to rotate own private key
|
||||
Please go to:
|
||||
|
||||
@@ -253,7 +253,7 @@ Enter your Client Secret: CLIENTSECRET
|
||||
6. Go back to your browser and click OK to close the "OAuth client" popup if it's still open.
|
||||
That's it! Your GAM Project is created and ready to use.
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Enable GAM7 client access
|
||||
|
||||
@@ -261,7 +261,7 @@ You select a list of scopes, GAM uses a browser to get final authorization from
|
||||
writes the credentials into the file oauth2.txt.
|
||||
|
||||
```
|
||||
admin@server:/Users/admin$ gam oauth create
|
||||
gamteam@server:/Users/gamteam$ gam oauth create
|
||||
|
||||
[*] 0) Calendar API (supports readonly)
|
||||
[*] 1) Chrome Browser Cloud Management API (supports readonly)
|
||||
@@ -328,7 +328,7 @@ Continue to authorization by entering a 'c'
|
||||
|
||||
Please enter 0-50[a|r] or s|u|e|c: c
|
||||
|
||||
Enter your Google Workspace admin email address? admin@domain.com
|
||||
Enter your Google Workspace admin email address? gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on this computer or on another computer:
|
||||
|
||||
@@ -340,16 +340,16 @@ click the Allow button, paste "Unable to connect" URL from other computer (only
|
||||
Enter verification code or paste "Unable to connect" URL from other computer (only URL data up to &scope required):
|
||||
|
||||
The authentication flow has completed.
|
||||
Client OAuth2 File: /Users/admin/GAMConfig/oauth2.txt, Created
|
||||
Client OAuth2 File: /Users/gamteam/GAMConfig/oauth2.txt, Created
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
|
||||
If clicking on the link in the instructions does not work (i.e. you get a 404 or 400 error message, instead of something about 'unable to connect') the URL in the link is too long. Most likely, you have selected all scopes. Try again with fewer scopes until it works. (there is no harm in repeatedly trying)
|
||||
|
||||
### Enable GAM7 service account access.
|
||||
```
|
||||
admin@server:/Users/admin$ gam user admin@domain.com update serviceaccount
|
||||
gamteam@server:/Users/gamteam$ gam user gamteam@domain.com update serviceaccount
|
||||
[*] 0) AlertCenter API
|
||||
[*] 1) Analytics API - read only
|
||||
[*] 2) Analytics Admin API - read only
|
||||
@@ -413,7 +413,7 @@ Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ FAIL (1/38)
|
||||
https://sites.google.com/feeds FAIL (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly FAIL (3/38)
|
||||
@@ -464,7 +464,7 @@ Click AUTHORIZE
|
||||
When the box closes you're done
|
||||
After authorizing it may take some time for this test to pass so wait a few moments and then try this command again.
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
The link shown in the error message should take you directly to the authorization screen.
|
||||
If not, make sure that you are logged in as a domain admin, then re-enter the link.
|
||||
@@ -474,14 +474,14 @@ If not, make sure that you are logged in as a domain admin, then re-enter the li
|
||||
Wait a moment and then perform the following command; it it still fails, wait a bit longer, it can sometimes take serveral minutes
|
||||
for the authorization to complete.
|
||||
```
|
||||
admin@server:/Users/admin$ gam user admin@domain.com check serviceaccount
|
||||
gamteam@server:/Users/gamteam$ gam user gamteam@domain.com check serviceaccount
|
||||
System time status
|
||||
Your system time differs from admin.googleapis.com by less than 1 second PASS
|
||||
Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ PASS (1/38)
|
||||
https://sites.google.com/feeds PASS (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly PASS (3/38)
|
||||
@@ -524,14 +524,14 @@ All scopes PASSED!
|
||||
|
||||
Service Account Client name: SVCACCTID is fully authorized.
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Update gam.cfg with some basic values
|
||||
* `customer_id` - Having this data keeps Gam from having to make extra API calls
|
||||
* `domain` - This allows you to omit the domain portion of email addresses
|
||||
* `timezone local` - Gam will convert all UTC times to your local timezone
|
||||
```
|
||||
admin@server:/Users/admin$ gam info domain
|
||||
gamteam@server:/Users/gamteam$ gam info domain
|
||||
Customer ID: C01234567
|
||||
Primary Domain: domain.com
|
||||
Customer Creation Time: 2007-06-06T15:47:55.444Z
|
||||
@@ -539,8 +539,8 @@ Primary Domain Verified: True
|
||||
Default Language: en
|
||||
...
|
||||
|
||||
admin@server:/Users/admin$ gam config customer_id C01234567 domain domain.com timezone local save verify
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Saved
|
||||
gamteam@server:/Users/gamteam$ gam config customer_id C01234567 domain domain.com timezone local save verify
|
||||
Config File: /Users/gamteam/GAMConfig/gam.cfg, Saved
|
||||
Section: DEFAULT
|
||||
...
|
||||
customer_id = C01234567
|
||||
@@ -550,12 +550,12 @@ Section: DEFAULT
|
||||
timezone = local
|
||||
...
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
|
||||
## Windows
|
||||
|
||||
In these examples, your Google Super admin is shown as admin@domain.com; replace with the
|
||||
In these examples, your Google Super admin is shown as gamteam@domain.com; replace with the
|
||||
actual email adddress.
|
||||
|
||||
This example assumes that GAM7 has been installed in C:\GAM7; if you've installed
|
||||
@@ -645,7 +645,7 @@ C:\>gam create project
|
||||
WARNING: Config File: C:\GAMConfig\gam.cfg, Item: client_secrets_json, Value: C:\GAMConfig\client_secrets.json, Not Found
|
||||
WARNING: Config File: C:\GAMConfig\gam.cfg, Item: oauth2service_json, Value: C:\GAMConfig\oauth2service.json, Not Found
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gamteam@domain.com
|
||||
|
||||
Your browser has been opened to visit:
|
||||
|
||||
@@ -714,7 +714,7 @@ C:\>gam create project
|
||||
WARNING: Config File: C:\GAMConfig\gam.cfg, Item: client_secrets_json, Value: C:\GAMConfig\client_secrets.json, Not Found
|
||||
WARNING: Config File: C:\GAMConfig\gam.cfg, Item: oauth2service_json, Value: C:\GAMConfig\oauth2service.json, Not Found
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on other computer:
|
||||
|
||||
@@ -848,7 +848,7 @@ Continue to authorization by entering a 'c'
|
||||
|
||||
Please enter 0-50[a|r] or s|u|e|c: c
|
||||
|
||||
Enter your Google Workspace admin email address? admin@domain.com
|
||||
Enter your Google Workspace admin email address? gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on this computer or on another computer:
|
||||
|
||||
@@ -866,7 +866,7 @@ C:\>
|
||||
```
|
||||
### Enable GAM7 service account access.
|
||||
```
|
||||
C:\>gam user admin@domain.com update serviceaccount
|
||||
C:\>gam user gamteam@domain.com update serviceaccount
|
||||
[*] 0) AlertCenter API
|
||||
[*] 1) Analytics API - read only
|
||||
[*] 2) Analytics Admin API - read only
|
||||
@@ -930,7 +930,7 @@ Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ FAIL (1/38)
|
||||
https://sites.google.com/feeds FAIL (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly FAIL (3/38)
|
||||
@@ -991,14 +991,14 @@ If not, make sure that you are logged in as a domain admin, then re-enter the li
|
||||
Wait a moment and then perform the following command; it it still fails, wait a bit longer, it can sometimes take serveral minutes
|
||||
for the authorization to complete.
|
||||
```
|
||||
C:\>gam user admin@domain.com check serviceaccount
|
||||
C:\>gam user gamteam@domain.com check serviceaccount
|
||||
System time status
|
||||
Your system time differs from admin.googleapis.com by less than 1 second PASS
|
||||
Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ PASS (1/38)
|
||||
https://sites.google.com/feeds PASS (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly PASS (3/38)
|
||||
|
||||
@@ -10,30 +10,30 @@ and all necessary authentications.
|
||||
|
||||
## Linux and MacOS and Google Cloud Shell
|
||||
|
||||
In these examples, your Google Super admin is shown as admin@domain.com; replace with the
|
||||
In these examples, your Google Super admin is shown as gamteam@domain.com; replace with the
|
||||
actual email adddress.
|
||||
|
||||
In these examples, the user home folder is shown as /Users/admin; adjust according to your
|
||||
In these examples, the user home folder is shown as /Users/gamteam; adjust according to your
|
||||
specific situation; e.g., /home/administrator.
|
||||
|
||||
This example assumes that GAM7 has been installed in /Users/admin/bin/gam7.
|
||||
This example assumes that GAM7 has been installed in /Users/gamteam/bin/gam7.
|
||||
If you've installed GAM7 in another directory, substitute that value in the directions.
|
||||
|
||||
### Set a configuration directory
|
||||
|
||||
The default GAM configuration directory is /Users/admin/.gam; for more flexibility you
|
||||
The default GAM configuration directory is /Users/gamteam/.gam; for more flexibility you
|
||||
probably want to select a non-hidden location. This example assumes that the GAM
|
||||
configuration directory will be /Users/admin/GAMConfig; If you've chosen another directory,
|
||||
configuration directory will be /Users/gamteam/GAMConfig; If you've chosen another directory,
|
||||
substitute that value in the directions.
|
||||
|
||||
Make the directory:
|
||||
```
|
||||
admin@server:/Users/admin$ mkdir -p /Users/admin/GAMConfig
|
||||
gamteam@server:/Users/gamteam$ mkdir -p /Users/gamteam/GAMConfig
|
||||
```
|
||||
|
||||
Add the following line:
|
||||
```
|
||||
export GAMCFGDIR="/Users/admin/GAMConfig"
|
||||
export GAMCFGDIR="/Users/gamteam/GAMConfig"
|
||||
```
|
||||
to one of these files based on your shell:
|
||||
```
|
||||
@@ -45,34 +45,34 @@ to one of these files based on your shell:
|
||||
|
||||
Issue the following command replacing `<Filename>` with the name of the file you edited:
|
||||
```
|
||||
admin@server:/Users/admin$ source <Filename>
|
||||
gamteam@server:/Users/gamteam$ source <Filename>
|
||||
```
|
||||
|
||||
You need to make sure the GAM configuration directory actually exists. Test that like this:
|
||||
```
|
||||
admin@server:/Users/admin$ ls -l $GAMCFGDIR
|
||||
gamteam@server:/Users/gamteam$ ls -l $GAMCFGDIR
|
||||
```
|
||||
|
||||
### Set a working directory
|
||||
|
||||
You should establish a GAM working directory; you will store your GAM related
|
||||
data in this folder and execute GAM commands from this folder. You should not use
|
||||
/Users/admin/bin/gam7 or /Users/admin/GAMConfig for this purpose.
|
||||
This example assumes that the GAM working directory will be /Users/admin/GAMWork; If you've chosen
|
||||
/Users/gamteam/bin/gam7 or /Users/gamteam/GAMConfig for this purpose.
|
||||
This example assumes that the GAM working directory will be /Users/gamteam/GAMWork; If you've chosen
|
||||
another directory, substitute that value in the directions.
|
||||
|
||||
Make the directory:
|
||||
```
|
||||
admin@server:/Users/admin$ mkdir -p /Users/admin/GAMWork
|
||||
gamteam@server:/Users/gamteam$ mkdir -p /Users/gamteam/GAMWork
|
||||
```
|
||||
|
||||
### Set an alias
|
||||
You should set an alias to point to /Users/admin/bin/gam7/gam so you can operate from the /Users/admin/GAMWork directory.
|
||||
You should set an alias to point to /Users/gamteam/bin/gam7/gam so you can operate from the /Users/gamteam/GAMWork directory.
|
||||
Aliases aren't available in scripts, so you may want to set a symlink instead, see below.
|
||||
|
||||
Add the following line:
|
||||
```
|
||||
alias gam="/Users/admin/bin/gam7/gam"
|
||||
alias gam="/Users/gamteam/bin/gam7/gam"
|
||||
```
|
||||
to one of these files based on your shell:
|
||||
```
|
||||
@@ -85,62 +85,62 @@ to one of these files based on your shell:
|
||||
|
||||
If you already have an alias for legacy GAM but are no longer going to run it, delete these lines:
|
||||
```
|
||||
function gam() { "/Users/admin/bin/gam/gam" "$@" ; }"
|
||||
alias gam="/Users/admin/bin/gam/gam"
|
||||
function gam() { "/Users/gamteam/bin/gam/gam" "$@" ; }"
|
||||
alias gam="/Users/gamteam/bin/gam/gam"
|
||||
```
|
||||
|
||||
If you already have an alias for legacy GAM and want to run it and GAM7, give your old alias a different name:
|
||||
```
|
||||
function gamstd() { "/Users/admin/bin/gam/gam" "$@" ; }"
|
||||
alias gamstd="/Users/admin/bin/gam/gam"
|
||||
function gamstd() { "/Users/gamteam/bin/gam/gam" "$@" ; }"
|
||||
alias gamstd="/Users/gamteam/bin/gam/gam"
|
||||
```
|
||||
|
||||
Issue the following command replacing `<Filename>` with the name of the file you edited:
|
||||
```
|
||||
admin@server:/Users/admin$ source <Filename>
|
||||
gamteam@server:/Users/gamteam$ source <Filename>
|
||||
```
|
||||
|
||||
### Set a symlink
|
||||
Set a symlink in `/usr/local/bin` (or some other location on $PATH) to point to GAM.
|
||||
```
|
||||
admin@server:/Users/admin$ ln -s "/Users/admin/bin/gam7/gam" /usr/local/bin/gam
|
||||
gamteam@server:/Users/gamteam$ ln -s "/Users/gamteam/bin/gam7/gam" /usr/local/bin/gam
|
||||
```
|
||||
|
||||
Set environment variable OLDGAMPATH to point to the existing Gam directory; /Users/admin/bin/gam will be used in this example.
|
||||
Set environment variable OLDGAMPATH to point to the existing Gam directory; /Users/gamteam/bin/gam will be used in this example.
|
||||
If your existing Gam is in another directory, substitute that value in the directions.
|
||||
```
|
||||
admin@server:/Users/admin$ export OLDGAMPATH=/Users/admin/bin/gam
|
||||
gamteam@server:/Users/gamteam$ export OLDGAMPATH=/Users/gamteam/bin/gam
|
||||
```
|
||||
Verify that OLDGAMPATH points to the correct location.
|
||||
```
|
||||
admin@server:/Users/admin$ ls -l $OLDGAMPATH/*.json
|
||||
-rw-r-----@ 1 admin staff 553 Feb 26 10:39 /Users/admin/bin/gam/client_secrets.json
|
||||
-rw-r-----@ 1 admin staff 2377 Feb 26 10:39 /Users/admin/bin/gam/oauth2service.json
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$ ls -l $OLDGAMPATH/*.json
|
||||
-rw-r-----@ 1 admin staff 553 Feb 26 10:39 /Users/gamteam/bin/gam/client_secrets.json
|
||||
-rw-r-----@ 1 admin staff 2377 Feb 26 10:39 /Users/gamteam/bin/gam/oauth2service.json
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Initialize GAM7; this should be the first GAM7 command executed.
|
||||
```
|
||||
admin@server:/Users/admin$ gam config drive_dir /Users/admin/GAMWork verify
|
||||
Created: /Users/admin/GAMConfig
|
||||
Created: /Users/admin/GAMConfig/gamcache
|
||||
Copied: /Users/admin/bin/gam/oauth2service.json, To: /Users/admin/GAMConfig/oauth2service.json
|
||||
Copied: /Users/admin/bin/gam/oauth2.txt, To: /Users/admin/GAMConfig/oauth2.txt
|
||||
Copied: /Users/admin/bin/gam/client_secrets.json, To: /Users/admin/GAMConfig/client_secrets.json
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Initialized
|
||||
gamteam@server:/Users/gamteam$ gam config drive_dir /Users/gamteam/GAMWork verify
|
||||
Created: /Users/gamteam/GAMConfig
|
||||
Created: /Users/gamteam/GAMConfig/gamcache
|
||||
Copied: /Users/gamteam/bin/gam/oauth2service.json, To: /Users/gamteam/GAMConfig/oauth2service.json
|
||||
Copied: /Users/gamteam/bin/gam/oauth2.txt, To: /Users/gamteam/GAMConfig/oauth2.txt
|
||||
Copied: /Users/gamteam/bin/gam/client_secrets.json, To: /Users/gamteam/GAMConfig/client_secrets.json
|
||||
Config File: /Users/gamteam/GAMConfig/gam.cfg, Initialized
|
||||
Section: DEFAULT
|
||||
...
|
||||
cache_dir = /Users/admin/GAMConfig/gamcache
|
||||
cache_dir = /Users/gamteam/GAMConfig/gamcache
|
||||
...
|
||||
config_dir = /Users/admin/GAMConfig
|
||||
config_dir = /Users/gamteam/GAMConfig
|
||||
...
|
||||
drive_dir = /Users/admin/GAMWork
|
||||
drive_dir = /Users/gamteam/GAMWork
|
||||
...
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Verify initialization, this was a successful installation.
|
||||
```
|
||||
admin@server:/Users/admin$ ls -l $GAMCFGDIR
|
||||
gamteam@server:/Users/gamteam$ ls -l $GAMCFGDIR
|
||||
total 48
|
||||
-rw-r-----+ 1 admin staff 553 Mar 3 09:23 client_secrets.json
|
||||
-rw-r-----+ 1 admin staff 1069 Mar 3 09:23 gam.cfg
|
||||
@@ -149,21 +149,21 @@ drwxr-x---+ 2 admin staff 68 Mar 3 09:23 gamcache
|
||||
-rw-r-----+ 1 admin staff 5104 Mar 3 09:23 oauth2.txt
|
||||
-rw-rw-rw-+ 1 admin staff 0 Mar 3 09:23 oauth2.txt.lock
|
||||
-rw-r-----+ 1 admin staff 2377 Mar 3 09:23 oauth2service.json
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
If the verification looks like this, then you'll have to copy client_secrets.json and oauth2service.json manually.
|
||||
```
|
||||
admin@server:/Users/admin$ ls -l $GAMCFGDIR
|
||||
gamteam@server:/Users/gamteam$ ls -l $GAMCFGDIR
|
||||
total 40
|
||||
-rw-r-----+ 1 admin admin 1427 Nov 1 11:38 gam.cfg
|
||||
drwxr-x---+ 16 admin admin 544 Nov 2 07:25 gamcache
|
||||
-rw-r--r--+ 1 admin admin 10 Nov 2 15:31 lastupdatecheck.txt
|
||||
-rw-rw-rw-+ 1 admin admin 0 Sep 19 17:28 oauth2.txt.lock
|
||||
|
||||
admin@server:/Users/admin$ cp -p $OLDGAMPATH/client_secrets.json $GAMCFGDIR/
|
||||
admin@server:/Users/admin$ cp -p $OLDGAMPATH/oauth2service.json $GAMCFGDIR/
|
||||
admin@server:/Users/admin$ cp -p $OLDGAMPATH/oauth2.txt $GAMCFGDIR/
|
||||
admin@server:/Users/admin$ ls -l $GAMCFGDIR
|
||||
gamteam@server:/Users/gamteam$ cp -p $OLDGAMPATH/client_secrets.json $GAMCFGDIR/
|
||||
gamteam@server:/Users/gamteam$ cp -p $OLDGAMPATH/oauth2service.json $GAMCFGDIR/
|
||||
gamteam@server:/Users/gamteam$ cp -p $OLDGAMPATH/oauth2.txt $GAMCFGDIR/
|
||||
gamteam@server:/Users/gamteam$ ls -l $GAMCFGDIR
|
||||
total 40
|
||||
-rw-r-----+ 1 admin staff 553 Mar 3 09:23 client_secrets.json
|
||||
-rw-r-----+ 1 admin staff 1069 Mar 3 09:23 gam.cfg
|
||||
@@ -175,9 +175,9 @@ drwxr-x---+ 2 admin staff 68 Mar 3 09:23 gamcache
|
||||
```
|
||||
### Update your project with local browser to include the additional APIs that GAM7 uses.
|
||||
```
|
||||
admin@server:/Users/admin$ gam update project
|
||||
gamteam@server:/Users/gamteam$ gam update project
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? gamteam@domain.com
|
||||
|
||||
Your browser has been opened to visit:
|
||||
|
||||
@@ -205,14 +205,14 @@ Enable 3 APIs
|
||||
API: groupsmigration.googleapis.com, Enabled (2/3)
|
||||
API: sheets.googleapis.com, Enabled (3/3)
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Update your project without local browser (Google Cloud Shell for instance) to include the additional APIs that GAM7 uses
|
||||
```
|
||||
admin@server:/Users/admin$ gam config no_browser true save
|
||||
admin@server:/Users/admin$ gam update project
|
||||
gamteam@server:/Users/gamteam$ gam config no_browser true save
|
||||
gamteam@server:/Users/gamteam$ gam update project
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on other computer:
|
||||
|
||||
@@ -239,7 +239,7 @@ Enable 3 APIs
|
||||
API: groupsmigration.googleapis.com, Enabled (2/3)
|
||||
API: sheets.googleapis.com, Enabled (3/3)
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Enable GAM7 client access
|
||||
|
||||
@@ -249,17 +249,17 @@ You select a list of scopes, GAM uses a browser to get final authorization from
|
||||
writes the credentials into the file oauth2.txt.
|
||||
|
||||
```
|
||||
admin@server:/Users/admin$ rm -f /Users/admin/GAMConfig/oauth2.txt
|
||||
admin@server:/Users/admin$ gam version
|
||||
WARNING: Config File: /Users/admin/GAMConfig/gam.cfg, Section: DEFAULT, Item: oauth2_txt, Value: /Users/admin/GAMConfig/oauth2.txt, Not Found
|
||||
GAM 7.30.01 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
gamteam@server:/Users/gamteam$ rm -f /Users/gamteam/GAMConfig/oauth2.txt
|
||||
gamteam@server:/Users/gamteam$ gam version
|
||||
WARNING: Config File: /Users/gamteam/GAMConfig/gam.cfg, Section: DEFAULT, Item: oauth2_txt, Value: /Users/gamteam/GAMConfig/oauth2.txt, Not Found
|
||||
GAM 7.34.05 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.14.1 64-bit final
|
||||
macOS Tahoe 26.1 x86_64
|
||||
Path: /Users/admin/bin/gam7
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Python 3.14.3 64-bit final
|
||||
macOS Tahoe 26.3 arm64
|
||||
Path: /Users/gamteam/bin/gam7
|
||||
Config File: /Users/gamteam/GAMConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
|
||||
admin@server:/Users/admin$ gam oauth create
|
||||
gamteam@server:/Users/gamteam$ gam oauth create
|
||||
|
||||
[*] 0) Calendar API (supports readonly)
|
||||
[*] 1) Chrome Browser Cloud Management API (supports readonly)
|
||||
@@ -326,7 +326,7 @@ Continue to authorization by entering a 'c'
|
||||
|
||||
Please enter 0-50[a|r] or s|u|e|c: c
|
||||
|
||||
Enter your Google Workspace admin email address? admin@domain.com
|
||||
Enter your Google Workspace admin email address? gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on this computer or on another computer:
|
||||
|
||||
@@ -338,13 +338,13 @@ click the Allow button, paste "Unable to connect" URL from other computer (only
|
||||
Enter verification code or paste "Unable to connect" URL from other computer (only URL data up to &scope required):
|
||||
|
||||
The authentication flow has completed.
|
||||
Client OAuth2 File: /Users/admin/GAMConfig/oauth2.txt, Created
|
||||
Client OAuth2 File: /Users/gamteam/GAMConfig/oauth2.txt, Created
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Enable GAM7 service account access.
|
||||
```
|
||||
admin@server:/Users/admin$ gam user admin@domain.com update serviceaccount
|
||||
gamteam@server:/Users/gamteam$ gam user gamteam@domain.com update serviceaccount
|
||||
[*] 0) AlertCenter API
|
||||
[*] 1) Analytics API - read only
|
||||
[*] 2) Analytics Admin API - read only
|
||||
@@ -408,7 +408,7 @@ Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ PASS (1/38)
|
||||
https://sites.google.com/feeds FAIL (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly FAIL (3/38)
|
||||
@@ -459,7 +459,7 @@ Click AUTHORIZE
|
||||
When the box closes you're done
|
||||
After authorizing it may take some time for this test to pass so wait a few moments and then try this command again.
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
The link shown in the error message should take you directly to the authorization screen.
|
||||
If not, make sure that you are logged in as a domain admin, then re-enter the link.
|
||||
@@ -469,7 +469,7 @@ If not, make sure that you are logged in as a domain admin, then re-enter the li
|
||||
Wait a moment and then perform the following command; it it still fails, wait a bit longer, it can sometimes take serveral minutes
|
||||
for the authorization to complete.
|
||||
```
|
||||
admin@server:/Users/admin$ gam user admin@domain.com check serviceaccount
|
||||
gamteam@server:/Users/gamteam$ gam user gamteam@domain.com check serviceaccount
|
||||
|
||||
System time status
|
||||
Your system time differs from admin.googleapis.com by less than 1 second PASS
|
||||
@@ -477,7 +477,7 @@ Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ PASS (1/38)
|
||||
https://sites.google.com/feeds PASS (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly PASS (3/38)
|
||||
@@ -519,14 +519,14 @@ Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
All scopes PASSED!
|
||||
Service Account Client name: SVCACCTID is fully authorized.
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
### Update gam.cfg with some basic values
|
||||
* `customer_id` - Having this data keeps Gam from having to make extra API calls
|
||||
* `domain` - This allows you to omit the domain portion of email addresses
|
||||
* `timezone local` - Gam will convert all UTC times to your local timezone
|
||||
```
|
||||
admin@server:/Users/admin$ gam info domain
|
||||
gamteam@server:/Users/gamteam$ gam info domain
|
||||
Customer ID: C01234567
|
||||
Primary Domain: domain.com
|
||||
Customer Creation Time: 2007-06-06T15:47:55.444Z
|
||||
@@ -534,8 +534,8 @@ Primary Domain Verified: True
|
||||
Default Language: en
|
||||
...
|
||||
|
||||
admin@server:/Users/admin$ gam config customer_id C01234567 domain domain.com timezone local save verify
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Saved
|
||||
gamteam@server:/Users/gamteam$ gam config customer_id C01234567 domain domain.com timezone local save verify
|
||||
Config File: /Users/gamteam/GAMConfig/gam.cfg, Saved
|
||||
Section: DEFAULT
|
||||
activity_max_results = 100
|
||||
admin_email = ''
|
||||
@@ -546,19 +546,21 @@ Section: DEFAULT
|
||||
bail_on_internal_error_tries = 2
|
||||
batch_size = 50
|
||||
cacerts_pem = ''
|
||||
cache_dir = /Users/admin/GAMConfig/gamcache
|
||||
cache_dir = /Users/gamteam/GAMConfig/gamcache
|
||||
cache_discovery_only = true
|
||||
channel_customer_id = ''
|
||||
charset = utf-8
|
||||
chat_max_results = 100
|
||||
classroom_max_results = 0
|
||||
client_secrets_json = client_secrets.json ; /Users/admin/GAMConfig/client_secrets.json
|
||||
client_secrets_json = client_secrets.json ; /Users/gamteam/GAMConfig/client_secrets.json
|
||||
clock_skew_in_seconds = 10
|
||||
cmdlog = ''
|
||||
cmdlog_max_backups = 5
|
||||
cmdlog_max_kilo_bytes = 1000
|
||||
config_dir = /Users/admin/GAMConfig
|
||||
config_dir = /Users/gamteam/GAMConfig
|
||||
contact_max_results = 100
|
||||
csv_input_column_delimiter = ,
|
||||
csv_input_no_escape_char = true
|
||||
csv_input_quote_char = '"'
|
||||
csv_input_row_drop_filter = ''
|
||||
csv_input_row_drop_filter_mode = anymatch
|
||||
@@ -571,32 +573,48 @@ Section: DEFAULT
|
||||
csv_output_header_drop_filter = ''
|
||||
csv_output_header_filter = ''
|
||||
csv_output_header_force = ''
|
||||
csv_output_header_order = ''
|
||||
csv_output_header_required = ''
|
||||
csv_output_line_terminator = lf
|
||||
csv_output_no_escape_char = false
|
||||
csv_output_quote_char = '"'
|
||||
csv_output_row_drop_filter = ''
|
||||
csv_output_row_drop_filter_mode = anymatch
|
||||
csv_output_row_filter = ''
|
||||
csv_output_row_filter_mode = allmatch
|
||||
csv_output_row_limit = 0
|
||||
csv_output_sort_headers = ''
|
||||
csv_output_subfield_delimiter = '.'
|
||||
csv_output_timestamp_column = ''
|
||||
csv_output_users_audit = false
|
||||
customer_id = C01234567
|
||||
debug_level = 0
|
||||
debug_redaction = true
|
||||
developer_preview_api_key = ''
|
||||
developer_preview_apis = ''
|
||||
device_max_results = 200
|
||||
domain = domain.com
|
||||
drive_dir = /Users/admin/GAMWork
|
||||
drive_dir = /Users/gamteam/GAMWork
|
||||
drive_max_results = 1000
|
||||
drive_v3_native_names = true
|
||||
email_batch_size = 50
|
||||
enable_dasa = false
|
||||
enable_gcloud_reauth = false
|
||||
enforce_expansive_access = true
|
||||
event_max_results = 250
|
||||
extra_args = ''
|
||||
gmail_cse_incert_dir = ''
|
||||
gmail_cse_inkey_dir = ''
|
||||
input_dir = .
|
||||
inter_batch_wait = 0
|
||||
license_max_results = 100
|
||||
license_skus = ''
|
||||
member_max_results = 200
|
||||
member_max_results_ci_basic = 1000
|
||||
member_max_results_ci_full = 500
|
||||
message_batch_size = 50
|
||||
message_max_results = 500
|
||||
mobile_max_results = 100
|
||||
multiprocess_pool_limit = 0
|
||||
never_time = Never
|
||||
no_browser = false
|
||||
no_cache = false
|
||||
@@ -604,15 +622,17 @@ Section: DEFAULT
|
||||
no_verify_ssl = false
|
||||
num_tbatch_threads = 2
|
||||
num_threads = 5
|
||||
oauth2_txt = oauth2.txt ; /Users/admin/GAMConfig/oauth2.txt
|
||||
oauth2service_json = oauth2service.json ; /Users/admin/GAMConfig/oauth2service.json
|
||||
oauth2_txt = oauth2.txt ; /Users/gamteam/GAMConfig/oauth2.txt
|
||||
oauth2service_json = oauth2service.json ; /Users/gamteam/GAMConfig/oauth2service.json
|
||||
output_dateformat = ''
|
||||
output_timeformat = ''
|
||||
people_max_results = 100
|
||||
print_agu_domains = ''
|
||||
print_cros_ous = ''
|
||||
print_cros_ous_and_children = ''
|
||||
process_wait_limit = 0
|
||||
quick_cros_move = false
|
||||
quick_info_user = False
|
||||
quick_info_user = false
|
||||
reseller_id = ''
|
||||
retry_api_service_not_available = false
|
||||
section = ''
|
||||
@@ -629,12 +649,13 @@ Section: DEFAULT
|
||||
smtp_username = ''
|
||||
timezone = local
|
||||
tls_max_version = ''
|
||||
tls_min_version = 'TLSv1_2'
|
||||
tls_min_version = 'TLSv1_3'
|
||||
todrive_clearfilter = false
|
||||
todrive_clientaccess = false
|
||||
todrive_conversion = true
|
||||
todrive_localcopy = false
|
||||
todrive_locale = ''
|
||||
todrive_no_escape_char = true
|
||||
todrive_nobrowser = false
|
||||
todrive_noemail = true
|
||||
todrive_parent = root
|
||||
@@ -647,16 +668,18 @@ Section: DEFAULT
|
||||
todrive_user = ''
|
||||
truncate_client_id = false
|
||||
update_cros_ou_with_id = false
|
||||
use_chat_admin_access = false
|
||||
use_course_owner_access = false
|
||||
use_projectid_as_name = false
|
||||
user_max_results = 500
|
||||
user_service_account_access_only = false
|
||||
|
||||
admin@server:/Users/admin$
|
||||
gamteam@server:/Users/gamteam$
|
||||
```
|
||||
|
||||
## Windows
|
||||
|
||||
In these examples, your Google Super admin is shown as admin@domain.com; replace with the
|
||||
In these examples, your Google Super admin is shown as gamteam@domain.com; replace with the
|
||||
actual email adddress.
|
||||
|
||||
This example assumes that GAM7 has been installed in C:\GAM7; if you've installed
|
||||
@@ -751,6 +774,7 @@ Section: DEFAULT
|
||||
cache_discovery_only = true
|
||||
channel_customer_id = ''
|
||||
charset = utf-8
|
||||
chat_max_results = 100
|
||||
classroom_max_results = 0
|
||||
client_secrets_json = client_secrets.json ; C:\GAMConfig\client_secrets.json
|
||||
clock_skew_in_seconds = 10
|
||||
@@ -760,6 +784,7 @@ Section: DEFAULT
|
||||
config_dir = C:\GAMConfig
|
||||
contact_max_results = 100
|
||||
csv_input_column_delimiter = ,
|
||||
csv_input_no_escape_char = true
|
||||
csv_input_quote_char = '"'
|
||||
csv_input_row_drop_filter = ''
|
||||
csv_input_row_drop_filter_mode = anymatch
|
||||
@@ -772,32 +797,48 @@ Section: DEFAULT
|
||||
csv_output_header_drop_filter = ''
|
||||
csv_output_header_filter = ''
|
||||
csv_output_header_force = ''
|
||||
csv_output_header_order = ''
|
||||
csv_output_header_required = ''
|
||||
csv_output_line_terminator = lf
|
||||
csv_output_no_escape_char = false
|
||||
csv_output_quote_char = '"'
|
||||
csv_output_row_drop_filter = ''
|
||||
csv_output_row_drop_filter_mode = anymatch
|
||||
csv_output_row_filter = ''
|
||||
csv_output_row_filter_mode = allmatch
|
||||
csv_output_row_limit = 0
|
||||
csv_output_sort_headers = ''
|
||||
csv_output_subfield_delimiter = '.'
|
||||
csv_output_timestamp_column = ''
|
||||
csv_output_users_audit = false
|
||||
customer_id = my_customer
|
||||
debug_level = 0
|
||||
debug_redaction = true
|
||||
developer_preview_api_key = ''
|
||||
developer_preview_apis = ''
|
||||
device_max_results = 200
|
||||
domain = ''
|
||||
drive_dir = C:\GAMWork
|
||||
drive_max_results = 1000
|
||||
drive_v3_native_names = true
|
||||
email_batch_size = 50
|
||||
enable_dasa = false
|
||||
enable_gcloud_reauth = false
|
||||
enforce_expansive_access = true
|
||||
event_max_results = 250
|
||||
extra_args = ''
|
||||
gmail_cse_incert_dir = ''
|
||||
gmail_cse_inkey_dir = ''
|
||||
input_dir = .
|
||||
inter_batch_wait = 0
|
||||
license_max_results = 100
|
||||
license_skus = ''
|
||||
member_max_results = 200
|
||||
member_max_results_ci_basic = 1000
|
||||
member_max_results_ci_full = 500
|
||||
message_batch_size = 50
|
||||
message_max_results = 500
|
||||
mobile_max_results = 100
|
||||
multiprocess_pool_limit = 0
|
||||
never_time = Never
|
||||
no_browser = false
|
||||
no_cache = false
|
||||
@@ -807,13 +848,15 @@ Section: DEFAULT
|
||||
num_threads = 5
|
||||
oauth2_txt = oauth2.txt ; C:\GAMConfig\oauth2.txt
|
||||
oauth2service_json = oauth2service.json ; C:\GAMConfig\oauth2service.json
|
||||
output_dateformat = ''
|
||||
output_timeformat = ''
|
||||
people_max_results = 100
|
||||
print_agu_domains = ''
|
||||
print_cros_ous = ''
|
||||
print_cros_ous_and_children = ''
|
||||
process_wait_limit = 0
|
||||
quick_cros_move = false
|
||||
quick_info_user = False
|
||||
quick_info_user = false
|
||||
reseller_id = ''
|
||||
retry_api_service_not_available = false
|
||||
section = ''
|
||||
@@ -830,12 +873,13 @@ Section: DEFAULT
|
||||
smtp_username = ''
|
||||
timezone = utc
|
||||
tls_max_version = ''
|
||||
tls_min_version = 'TLSv1_2'
|
||||
tls_min_version = 'TLSv1_3'
|
||||
todrive_clearfilter = false
|
||||
todrive_clientaccess = false
|
||||
todrive_conversion = true
|
||||
todrive_localcopy = false
|
||||
todrive_locale = ''
|
||||
todrive_no_escape_char = true
|
||||
todrive_nobrowser = false
|
||||
todrive_noemail = true
|
||||
todrive_parent = root
|
||||
@@ -848,6 +892,8 @@ Section: DEFAULT
|
||||
todrive_user = ''
|
||||
truncate_client_id = false
|
||||
update_cros_ou_with_id = false
|
||||
use_chat_admin_access = false
|
||||
use_course_owner_access = false
|
||||
use_projectid_as_name = false
|
||||
user_max_results = 500
|
||||
user_service_account_access_only = false
|
||||
@@ -919,7 +965,7 @@ C:\>dir %GAMCFGDIR%
|
||||
```
|
||||
C:\>gam update project
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? gamteam@domain.com
|
||||
|
||||
Your browser has been opened to visit:
|
||||
|
||||
@@ -951,7 +997,7 @@ C:\>
|
||||
C:\>gam config no_browser true save
|
||||
C:\>gam update project
|
||||
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? admin@domain.com
|
||||
Enter your Google Workspace admin or GCP project manager email address authorized to manage project(s) gam-project-abc-123-xyz? gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on other computer:
|
||||
|
||||
@@ -990,9 +1036,9 @@ writes the credentials into the file oauth2.txt.
|
||||
C:\>del C:\GAMConfig\oauth2.txt
|
||||
C:\>gam version
|
||||
WARNING: Config File: C:\GAMConfig\gam.cfg, Section: DEFAULT, Item: oauth2_txt, Value: C:\GAMConfig\oauth2.txt, Not Found
|
||||
GAM 7.30.01 - https://github.com/GAM-team/GAM - pythonsource
|
||||
GAM 7.34.05 - https://github.com/GAM-team/GAM - pythonsource
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.14.1 64-bit final
|
||||
Python 3.14.3 64-bit final
|
||||
Windows 11 10.0.26200 AMD64
|
||||
Path: C:\GAM7
|
||||
Config File: C:\GAMConfig\gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
@@ -1064,7 +1110,7 @@ Continue to authorization by entering a 'c'
|
||||
|
||||
Please enter 0-50[a|r] or s|u|e|c: c
|
||||
|
||||
Enter your Google Workspace admin email address? admin@domain.com
|
||||
Enter your Google Workspace admin email address? gamteam@domain.com
|
||||
|
||||
Go to the following link in a browser on this computer or on another computer:
|
||||
|
||||
@@ -1083,7 +1129,7 @@ C:\>
|
||||
|
||||
### Enable GAM7 service account access.
|
||||
```
|
||||
C:\>gam user admin@domain.com update serviceaccount
|
||||
C:\>gam user gamteam@domain.com update serviceaccount
|
||||
[*] 0) AlertCenter API
|
||||
[*] 1) Analytics API - read only
|
||||
[*] 2) Analytics Admin API - read only
|
||||
@@ -1147,7 +1193,7 @@ Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ PASS (1/38)
|
||||
https://sites.google.com/feeds FAIL (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly FAIL (3/38)
|
||||
@@ -1208,14 +1254,14 @@ If not, make sure that you are logged in as a domain admin, then re-enter the li
|
||||
Wait a moment and then perform the following command; it it still fails, wait a bit longer, it can sometimes take serveral minutes
|
||||
for the authorization to complete.
|
||||
```
|
||||
C:\>gam user admin@domain.com check serviceaccount
|
||||
C:\>gam user gamteam@domain.com check serviceaccount
|
||||
System time status
|
||||
Your system time differs from admin.googleapis.com by less than 1 second PASS
|
||||
Service Account Private Key Authentication
|
||||
Authentication PASS
|
||||
Service Account Private Key age; Google recommends rotating keys on a routine basis
|
||||
Service Account Private Key age: 1 day WARN
|
||||
Domain-wide Delegation authentication:, User: admin@domain.com, Scopes: 38
|
||||
Domain-wide Delegation authentication:, User: gamteam@domain.com, Scopes: 38
|
||||
https://mail.google.com/ PASS (1/38)
|
||||
https://sites.google.com/feeds PASS (2/38)
|
||||
https://www.googleapis.com/auth/analytics.readonly PASS (3/38)
|
||||
@@ -1289,6 +1335,7 @@ Section: DEFAULT
|
||||
cache_discovery_only = true
|
||||
channel_customer_id = ''
|
||||
charset = utf-8
|
||||
chat_max_results = 100
|
||||
classroom_max_results = 0
|
||||
client_secrets_json = client_secrets.json ; C:\GAMConfig\client_secrets.json
|
||||
clock_skew_in_seconds = 10
|
||||
@@ -1298,6 +1345,7 @@ Section: DEFAULT
|
||||
config_dir = C:\GAMConfig
|
||||
contact_max_results = 100
|
||||
csv_input_column_delimiter = ,
|
||||
csv_input_no_escape_char = true
|
||||
csv_input_quote_char = '"'
|
||||
csv_input_row_drop_filter = ''
|
||||
csv_input_row_drop_filter_mode = anymatch
|
||||
@@ -1310,32 +1358,48 @@ Section: DEFAULT
|
||||
csv_output_header_drop_filter = ''
|
||||
csv_output_header_filter = ''
|
||||
csv_output_header_force = ''
|
||||
csv_output_header_order = ''
|
||||
csv_output_header_required = ''
|
||||
csv_output_line_terminator = lf
|
||||
csv_output_no_escape_char = false
|
||||
csv_output_quote_char = '"'
|
||||
csv_output_row_drop_filter = ''
|
||||
csv_output_row_drop_filter_mode = anymatch
|
||||
csv_output_row_filter = ''
|
||||
csv_output_row_filter_mode = allmatch
|
||||
csv_output_row_limit = 0
|
||||
csv_output_sort_headers = ''
|
||||
csv_output_subfield_delimiter = '.'
|
||||
csv_output_timestamp_column = ''
|
||||
csv_output_users_audit = false
|
||||
customer_id = C01234567
|
||||
debug_level = 0
|
||||
debug_redaction = true
|
||||
developer_preview_api_key = ''
|
||||
developer_preview_apis = ''
|
||||
device_max_results = 200
|
||||
domain = domain.com
|
||||
drive_dir = C:\GAMWork
|
||||
drive_max_results = 1000
|
||||
drive_v3_native_names = true
|
||||
email_batch_size = 50
|
||||
enable_dasa = false
|
||||
enable_gcloud_reauth = false
|
||||
enforce_expansive_access = true
|
||||
event_max_results = 250
|
||||
extra_args = ''
|
||||
gmail_cse_incert_dir = ''
|
||||
gmail_cse_inkey_dir = ''
|
||||
input_dir = .
|
||||
inter_batch_wait = 0
|
||||
license_max_results = 100
|
||||
license_skus = ''
|
||||
member_max_results = 200
|
||||
member_max_results_ci_basic = 1000
|
||||
member_max_results_ci_full = 500
|
||||
message_batch_size = 50
|
||||
message_max_results = 500
|
||||
mobile_max_results = 100
|
||||
multiprocess_pool_limit = 0
|
||||
never_time = Never
|
||||
no_browser = false
|
||||
no_cache = false
|
||||
@@ -1353,7 +1417,7 @@ Section: DEFAULT
|
||||
print_cros_ous_and_children = ''
|
||||
process_wait_limit = 0
|
||||
quick_cros_move = false
|
||||
quick_info_user = False
|
||||
quick_info_user = false
|
||||
reseller_id = ''
|
||||
retry_api_service_not_available = false
|
||||
section = ''
|
||||
@@ -1370,12 +1434,13 @@ Section: DEFAULT
|
||||
smtp_username = ''
|
||||
timezone = local
|
||||
tls_max_version = ''
|
||||
tls_min_version = 'TLSv1_2'
|
||||
tls_min_version = 'TLSv1_3'
|
||||
todrive_clearfilter = false
|
||||
todrive_clientaccess = false
|
||||
todrive_conversion = true
|
||||
todrive_localcopy = false
|
||||
todrive_locale = ''
|
||||
todrive_no_escape_char = true
|
||||
todrive_nobrowser = false
|
||||
todrive_noemail = true
|
||||
todrive_parent = root
|
||||
@@ -1388,6 +1453,8 @@ Section: DEFAULT
|
||||
todrive_user = ''
|
||||
truncate_client_id = false
|
||||
update_cros_ou_with_id = false
|
||||
use_chat_admin_access = false
|
||||
use_course_owner_access = false
|
||||
use_projectid_as_name = false
|
||||
user_max_results = 500
|
||||
user_service_account_access_only = false
|
||||
|
||||
@@ -77,6 +77,7 @@
|
||||
<MimeTypeNameList> ::= "<MimeTypeName>(,<MimeTypeName>)*"
|
||||
<NamespaceList> ::= "<Namespace>(,<Namespace>)*"
|
||||
<NotesNameList> ::= "<NotesName>(,<NotesName>)*"
|
||||
<NumberRangeList> ::= "<NumberRange>(,<NumberRange>)*"
|
||||
<OrgUnitList> ::= "<OrgUnitItem>(,<OrgUnitItem>)*"
|
||||
<OtherContactsResourceNameList> ::= "<OtherContactsResourceName>(,<OtherContactsResourceName>)*"
|
||||
<PeopleResourceNameList> ::= "<PeopleResourceName>(,<PeopleResourceName>)*"
|
||||
|
||||
@@ -27,12 +27,13 @@ gam [<Select>] [showsections] [<SelectOutputFilter>|<SelectInputFilter>] [<Confi
|
||||
Select a section from gam.cfg and process a GAM command using values from that section.
|
||||
```
|
||||
<Select> ::=
|
||||
select <Section> [save] [verify]
|
||||
select <Section> [save] [verify [variables <RESearchPattern>]]
|
||||
```
|
||||
- `save`
|
||||
- Set `section = <Section>` in the `[DEFAULT]` section and write configuration data to gam.cfg
|
||||
- `verify`
|
||||
- Print the variable values for the selected section
|
||||
- Use `variables <RESearchPattern>` to display variables with names selected by `<RESearchPattern>`
|
||||
- Values are determined in this order: Selected section, DEFAULT section, Program default
|
||||
|
||||
If you enter `gam select <SectionName>` and nothing else on the command line,
|
||||
@@ -55,6 +56,7 @@ The only `<VariableNames>` recognized in this `<Section>` are:
|
||||
* `csv_output_header_drop_filter`
|
||||
* `csv_output_header_force`
|
||||
* `csv_output_header_order`
|
||||
* `csv_output_header_required`
|
||||
* `csv_output_row_filter`
|
||||
* `csv_output_row_filter_mode`
|
||||
* `csv_output_row_drop_filter`
|
||||
@@ -80,7 +82,7 @@ Set variables in gam.cfg.
|
||||
|
||||
```
|
||||
<Config> ::=
|
||||
config (<VariableName> [=] <Value>)* [save] [verify]
|
||||
config (<VariableName> [=] <Value>)* [save] [verify [variables <RESearchPattern>]]
|
||||
```
|
||||
- `<VariableName> [=] <Value>`
|
||||
- Set `<VariableName> = <Value>` in the current section
|
||||
@@ -90,6 +92,7 @@ Set variables in gam.cfg.
|
||||
- Write configuration data to gam.cfg
|
||||
- `verify`
|
||||
- Print the variable values for the current section
|
||||
- Use `variables <RESearchPattern>` to display variables with names selected by `<RESearchPattern>`
|
||||
- Values are determined in this order: Current section, DEFAULT section, Program default
|
||||
|
||||
You can prefix `<Config>` with `<Select>` to set a variable in a particular section.
|
||||
|
||||
34
wiki/No-Owner-Secondary-Calendars.md
Normal file
34
wiki/No-Owner-Secondary-Calendars.md
Normal file
@@ -0,0 +1,34 @@
|
||||
# Secondary Calendars with no Owner
|
||||
|
||||
Here's a start on how to get information for non-owned secondary calendars
|
||||
|
||||
Save the CSV file that Google sent you as NoOwnerSecCals.csv
|
||||
|
||||
Get calendar description and summary for non-owned secondary calendars.
|
||||
* There will be one row per calendar.
|
||||
```
|
||||
gam config num_threads 10 csv_output_header_force "calendarId,description,summary" redirect csv ./NOSC_Details.csv multiprocess redirect stderr - multiprocess csv NoOwnerSecCals.csv gam calendar "~Secondary calendar email" print settings fields description,summary
|
||||
```
|
||||
|
||||
Get event counts for non-owned secondary calendars.
|
||||
* There will be one row per calendar.
|
||||
```
|
||||
gam config num_threads 10 redirect csv ./NOSC_EventCounts.csv multiprocess redirect stderr - multiprocess csv NOSC_Details.csv gam calendar "~calendarId" print events countsonly addcsvdata description "~description" addcsvdata summary "~summary"
|
||||
```
|
||||
|
||||
Get summary for non-owned secondary calendars - Contains details, counts, ACLs
|
||||
* There will be one row per calendar/ACL combination
|
||||
```
|
||||
gam config num_threads 10 redirect csv ./NOSC_Summary.csv multiprocess redirect stderr - multiprocess csv NOSC_EventCounts.csv gam calendar "~calendarId" print acls noselfowner addcsvdata description "~description" addcsvdata summary "~summary" addcsvdata events "~events"
|
||||
```
|
||||
|
||||
You can add an owner.
|
||||
* Replace `admin@domain.com` with a super admin other than the one from: `gam oauth info`
|
||||
```
|
||||
gam config num_threads 10 redirect stdout ./Add_NOSC_Owner.txt multiprocess redirect stderr stdout csv NoOwnerSecCals.csv gam calendar "~Secondary calendar email" add acls owner admin@domain.com sendnotifications false
|
||||
```
|
||||
After inspecting NOSC_Summary.csv, you can delete the calendars if desired.
|
||||
* Replace `admin@domain.com` with the super admin specified in the previous step
|
||||
```
|
||||
gam config num_threads 10 redirect stdout ./Delete_NOSC.txt multiprocess redirect stderr stdout csv NoOwnerSecCals.csv gam user admin@domain.com remove calendar "~Secondary calendar email"
|
||||
``
|
||||
@@ -12,18 +12,24 @@
|
||||
- [User reports](#user-reports)
|
||||
|
||||
## API documentation
|
||||
Changes starting 2025-10-29.
|
||||
* [Activity Data Sources](https://support.google.com/a/answer/11482175)
|
||||
|
||||
Changes starting 2025-12-20
|
||||
* [Reports API - Admin log enhancements](https://workspaceupdates.googleblog.com/2025/12/google-workspace-audit-log-api.html)
|
||||
|
||||
Changes starting 2026-02-17.
|
||||
* [Reports API - Admin log event changes](https://support.google.com/a/answer/16601511)
|
||||
|
||||
These pages show event/parameter names; scroll down in the left column to: Reports.
|
||||
|
||||
* [Reports API - Activities](https://developers.google.com/admin-sdk/reports/v1/reference/activities)
|
||||
* [Reports API - Customer Usage](https://developers.google.com/admin-sdk/reports/v1/reference/customerUsageReports)
|
||||
* [Reports API - User Usage](https://developers.google.com/admin-sdk/reports/v1/reference/userUsageReport)
|
||||
These pages show event/parameter names:
|
||||
* [Reports API - Admin Activities](https://developers.google.com/workspace/admin/reports/v1/appendix/activity/admin-event-names)
|
||||
* [Reports API - Activities](https://developers.google.com/workspace/admin/reports/v1/appendix/activity/access-transparency)
|
||||
* [Reports API - Customer Usage](https://developers.google.com/workspace/admin/reports/v1/appendix/usage/customer)
|
||||
* [Reports API - User Usage](https://developers.google.com/workspace/admin/reports/v1/appendix/usage/user)
|
||||
|
||||
## Definitions
|
||||
```
|
||||
<NumberRange> ::= <Number>|(<Number>/<Number>)
|
||||
<NumberRangeList> ::= "<NumberRange>(,<NumberRange>)*"
|
||||
<DayOfWeek> ::= mon|tue|wed|thu|fri|sat|sun
|
||||
<Time> ::=
|
||||
<Year>-<Month>-<Day>(<Space>|T)<Hour>:<Minute>:<Second>[.<MilliSeconds>](Z|(+|-(<Hour>:<Minute>))) |
|
||||
@@ -45,54 +51,71 @@ config csv_output_row_filter "'\"accounts:used_quota_in_mb\":count>15000'"
|
||||
## Activity reports
|
||||
```
|
||||
<ActivityApplicationName> ::=
|
||||
accessevaluation|
|
||||
accesstransparency|access|
|
||||
admin|
|
||||
admindataaction|
|
||||
assignments|
|
||||
calendar|calendars|
|
||||
chat|
|
||||
chrome|
|
||||
classroom|
|
||||
cloudsearch|
|
||||
contacts|
|
||||
contextawareaccess|
|
||||
datamigration|
|
||||
datastudio|
|
||||
directorysync|
|
||||
drive|doc|docs|
|
||||
gcp|cloud|
|
||||
geminiinworkspaceapps|gemini|geminiforworkspace|
|
||||
gmail|
|
||||
gplus|currents|google+|
|
||||
graduation|
|
||||
groups|group|
|
||||
groupsenterprise|enterprisegroups|
|
||||
jamboard|
|
||||
keep|
|
||||
ldap|
|
||||
login|logins|
|
||||
meet|hangoutsmeet|
|
||||
meethardware|
|
||||
mobile|devices|
|
||||
profile|
|
||||
rules|
|
||||
saml|
|
||||
takeout|
|
||||
tasks|
|
||||
token|tokens|oauthtoken|
|
||||
useraccounts|
|
||||
vault
|
||||
|
||||
gam report <ActivityApplicationName> [todrive <ToDriveAttribute>*]
|
||||
[(user all|<UserItem>)|(orgunit|org|ou <OrgUnitPath> [showorgunit])|(select <UserTypeEntity>)]
|
||||
[userisactor]
|
||||
[([start <Time>] [end <Time>])|(range <Time> <Time>)|
|
||||
yesterday|today|thismonth|(previousmonths <Integer>)]
|
||||
[filter <String> (filtertime<String> <Time>)*]
|
||||
[event|events <EventNameList>] [ip <String>]
|
||||
[groupidfilter <String>]
|
||||
[gmaileventtypes <NumberRangeList>]
|
||||
[groupidfilter <String>] [resourcedetailsfilter <String>]
|
||||
[notimesort]
|
||||
[maxactivities <Number>] [maxevents <Number>] [maxresults <Number>]
|
||||
[countsonly [bydate|summary] [eventrowfilter]]
|
||||
(addcsvdata <FieldName> <String>)* [shownoactivities]
|
||||
```
|
||||
Select the application with `<ActivityApplicationName>`.
|
||||
|
||||
For all `<ActivityApplicationNames>` other than `admin`, select the users for whom information is desired.
|
||||
For all `<ActivityApplicationNames>`, select the users for whom information is desired.
|
||||
* `user all` - All users, the default; there is one API call
|
||||
* `user <UserItem>` - An individual user; there is one API call
|
||||
* `orgunit|org|ou <OrgUnitPath>` - All users in the specified OU; there is one API call
|
||||
* `showorgunit` - Add a column labelled `actor.orgUnitPath` to the output; an additional API call is made to get the email addresses of the users in `<OrgUnitPath>`
|
||||
* `select <UserTypeEntity>` - A selected collection of users, e.g., `select group staff@domain.com`; there is one API call per user
|
||||
|
||||
For `<ActivityApplicationName>` `admin`, the users selected are the admins that executed the command, not the targeted user.
|
||||
Use `filter "USER_EMAIL==user@domain.com"` to select the targeted user.
|
||||
For `<ActivityApplicationName>` `admin` and `chrome`, `orgunit|org|ou <OrgUnitPath>` does not work, use `select ou <OrgUnitPath>`.
|
||||
|
||||
For `<ActivityApplicationName>` `admin`, use option `userisactor` to display activities where the user executed the command that generated the activity.
|
||||
|
||||
Limit the time period.
|
||||
* `start <Time>`
|
||||
@@ -103,6 +126,20 @@ Limit the time period.
|
||||
* `thismonth` - The current calendar month up to the current time
|
||||
* `previousmonths <Integer>` - A number in the range 1 to 6 indicating calendar months previous to the current month
|
||||
|
||||
For `gam report gmail`, `start <Time>` and `end <Time>` should both be provided, and the scan duration should not be greater than 30 days.
|
||||
GAM will supply missing values:
|
||||
* No time information provided - GAM sets `range -30d today`
|
||||
* Only `start <Time>` provided - GAM sets `end <Time>+30d`
|
||||
* Only `end <Time>` provided - GAM sets `start <Time>-30d`
|
||||
|
||||
For `gam report gmail`, `gmaileventtypes <NumberRangeList>` can be used to limit the event types displayed.
|
||||
* See: https://developers.google.com/workspace/admin/reports/v1/appendix/activity/gmail
|
||||
|
||||
You can use the following filter to select a specific event; replace `X` with your desired value.
|
||||
```
|
||||
filter "event_info.mail_event_type==X"
|
||||
```
|
||||
|
||||
Apply API filters.
|
||||
* `filter|filters <String>` - `<String>` is a comma separated list of filter expressions.
|
||||
|
||||
@@ -111,6 +148,12 @@ The `filtertime<String> <Time>` value replaces the string `#filtertime<String>#`
|
||||
The characters following `filtertime` can be any combination of lowercase letters and numbers. This is most useful in scripts
|
||||
where you can specify a relative date without having to change the script.
|
||||
|
||||
Limit to those users that are a member of at least one of a list of groups.
|
||||
* `groupidfilter <String>` - Format: "id:abc123,id:xyz456"
|
||||
|
||||
Limit based on resource details.
|
||||
* `resourcedetailsfilter <String>` - See: https://developers.google.com/workspace/admin/reports/reference/rest/v1/activities/list#query-parameters
|
||||
|
||||
You can use `config csv_output_row_filter` to filter the events if the API filter can't produce the results you want.
|
||||
|
||||
Limit to a list of specific events.
|
||||
@@ -119,9 +162,6 @@ Limit to a list of specific events.
|
||||
Limit to a specific IP address.
|
||||
* `ip <String>`
|
||||
|
||||
Limit to those users that are a member of at least one of a list of groups.
|
||||
* `groupidfilter <String>` - Format: "id:abc123,id:xyz456"
|
||||
|
||||
Limit the total number of activites.
|
||||
* `maxactivities <Number>`
|
||||
|
||||
@@ -137,6 +177,9 @@ show the most recent activity/event; this can be useful when reporting drive act
|
||||
Add additional columns of data from the command line to the output.
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
By default, a reverse chronological sort is performed on all rows across multiple users and/or event names;
|
||||
this is consistent with the behavior in the Admin console. Use option `notimesort` to suppress this sort.
|
||||
|
||||
Display a row with a key value of `NoActivities` when there are no activities to report.
|
||||
* `shownoactivities`
|
||||
|
||||
|
||||
@@ -171,7 +171,7 @@
|
||||
withlink
|
||||
<DrivePermissionsFieldNameList> ::= "<DrivePermissionsFieldName>(,<DrivePermissionsFieldName>)*"
|
||||
|
||||
<QueryTeamDrive> ::= <String> See: https://developers.google.com/drive/api/v3/search-parameters
|
||||
<QuerySharedDrive> ::= <String> See: https://developers.google.com/workspace/drive/api/guides/search-shareddrives
|
||||
<SharedDriveACLRole> ::=
|
||||
manager|organizer|owner|
|
||||
contentmanager|fileorganizer|
|
||||
@@ -183,8 +183,8 @@
|
||||
<SharedDriveName> ::= <String>
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveID>|
|
||||
(teamdriveid <SharedDriveID>)|(teamdriveid:<SharedDriveID>)|
|
||||
(teamdrive <SharedDriveName>)|(teamdrive:<SharedDriveName>)
|
||||
(shareddriveid <SharedDriveID>)|(shareddriveid:<SharedDriveID>)|
|
||||
(shareddrive <SharedDriveName>)|(shareddrive:<SharedDriveName>)
|
||||
|
||||
<SharedDriveFieldName> ::=
|
||||
backgroundimagefile|
|
||||
@@ -199,11 +199,11 @@
|
||||
<SharedDriveFieldNameList> ::= "<SharedDriveFieldName>(,<SharedDriveFieldName>)*"
|
||||
|
||||
<SharedDriveIDEntity> ::=
|
||||
<DriveFileItem>|(teamdriveid <DriveFileItem>)|(teamdriveid:<DriveFileItem>)
|
||||
<DriveFileItem>|(shareddriveid <DriveFileItem>)|(shareddriveid:<DriveFileItem>)
|
||||
<SharedDriveNameEntity> ::=
|
||||
(teamdrive <SharedDriveName>)|(teamdrive:<SharedDriveName>)
|
||||
(shareddrive <SharedDriveName>)|(shareddrive:<SharedDriveName>)
|
||||
<SharedDriveAdminQueryEntity> ::=
|
||||
(teamdriveadminquery <QueryTeamDrive>)|(teamdriveadminquery:<QueryTeamDrive>)
|
||||
(shareddriveadminquery <QuerySharedDrive>)|(shareddriveadminquery:<QuerySharedDrive>)
|
||||
|
||||
<SharedDriveEntityAdmin> ::=
|
||||
<SharedDriveIDEntity> |
|
||||
@@ -327,11 +327,11 @@ When either of these options is chosen, no infomation about Shared Drive restric
|
||||
To retrieve the Shared Drive ID with `returnidonly`:
|
||||
```
|
||||
Linux/MacOS
|
||||
teamDriveId=$(gam create shareddrive ... returnidonly)
|
||||
shareddriveId=$(gam create shareddrive ... returnidonly)
|
||||
Windows PowerShell
|
||||
$teamDriveId = & gam create shareddrive ... returnidonly
|
||||
$shareddriveId = & gam create shareddrive ... returnidonly
|
||||
Windows Command Prompt
|
||||
for /f "delims=" %a in ('gam create shareddrive ... returnidonly') do set teamDriveId=%a
|
||||
for /f "delims=" %a in ('gam create shareddrive ... returnidonly') do set shareddriveId=%a
|
||||
```
|
||||
|
||||
## Bulk Create Shared Drives
|
||||
@@ -422,14 +422,14 @@ By default, Gam displays the information as an indented list of keys and values.
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
```
|
||||
gam [<UserTypeEntity>] show shareddrives
|
||||
[adminaccess|asadmin] [teamdriveadminquery|query <QueryTeamDrive>]
|
||||
[adminaccess|asadmin] [shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
[fields <SharedDriveFieldNameList>]
|
||||
[showwebviewlink text|hyperlink]
|
||||
[formatjson]
|
||||
```
|
||||
By default, all Shared Drives are displayed; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QuerySharedDrive>` - Use a query to select Shared Drives
|
||||
* `matchname <REMatchPattern>` - Retrieve Shared Drives with names that match a pattern.
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
|
||||
@@ -441,14 +441,14 @@ By default, Gam displays the information as an indented list of keys and values.
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
```
|
||||
gam [<UserTypeEntity>] print shareddrives [todrive <ToDriveAttribute>*]
|
||||
[adminaccess|asadmin] [teamdriveadminquery|query <QueryTeamDrive>]
|
||||
[adminaccess|asadmin] [shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
[fields <SharedDriveFieldNameList>]
|
||||
[showwebviewlink text|hyperlink]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, all Shared Drives are displayed; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QuerySharedDrive>` - Use a query to select Shared Drives
|
||||
* `matchname <REMatchPattern>` - Retrieve Shared Drives with names that match a pattern.
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
|
||||
@@ -498,7 +498,7 @@ Options `shareddriveadminquery|query` and `shareddrives|teamdrives` are mutually
|
||||
Options `shareddriveadminquery|query` and `orgunit|org|ou` require `adminaccess|asadmin`.
|
||||
|
||||
By default, organizers for all Shared Drives are displayed; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QuerySharedDrive>` - Use a query to select Shared Drives
|
||||
* `shareddrives|teamdrives <SharedDriveIDList>` - Select the Shared Drive IDs specified in `<SharedDriveIDList>`
|
||||
* `shareddrives|teamdrives select <FileSelector>|<CSVFileSelector>` - Select the Shared Drive IDs specified in `<FileSelector>|<CSVFileSelector>`
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
@@ -535,12 +535,12 @@ gam print shareddrives query "organizerCount = 0"
|
||||
Display the number of Shared Drives.
|
||||
```
|
||||
gam [<UserTypeEntity>] show|print shareddrives
|
||||
[adminaccess|asadmin] [teamdriveadminquery|query <QueryTeamDrive>]
|
||||
[adminaccess|asadmin] [shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
showitemcountonly
|
||||
```
|
||||
By default, all Shared Drives are counted; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QuerySharedDrive>` - Use a query to select Shared Drives
|
||||
* `matchname <REMatchPattern>` - Retrieve Shared Drives with names that match a pattern.
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
|
||||
@@ -758,7 +758,7 @@ gam config csv_output_header_drop_filter "User,createdTime,permission.photoLink,
|
||||
## Display Shared Drive access for selected Shared Drives
|
||||
```
|
||||
gam [<UserTypeEntity>] show shareddriveacls
|
||||
[adminaccess|asadmin] [teamdriveadminquery|query <QueryTeamDrive>]
|
||||
[adminaccess|asadmin] [shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
[user|group <EmailAddress> [checkgroups]] (role|roles <SharedDriveACLRoleList>)*
|
||||
<PermissionMatch>* [<PermissionMatchAction>] [pmselect]
|
||||
@@ -767,7 +767,7 @@ gam [<UserTypeEntity>] show shareddriveacls
|
||||
[formatjson]
|
||||
|
||||
gam [<UserTypeEntity>] print shareddriveacls [todrive <ToDriveAttribute>*]
|
||||
[adminaccess|asadmin] [teamdriveadminquery|query <QueryTeamDrive>]
|
||||
[adminaccess|asadmin] [shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
[user|group <EmailAddress> [checkgroups]] (role|roles <SharedDriveACLRoleList>)*
|
||||
<PermissionMatch>* [<PermissionMatchAction>] [pmselect]
|
||||
@@ -777,7 +777,7 @@ gam [<UserTypeEntity>] print shareddriveacls [todrive <ToDriveAttribute>*]
|
||||
|
||||
```
|
||||
By default, all Shared Drives are displayed; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QuerySharedDrive>` - Use a query to select Shared Drives
|
||||
* `matchname <REMatchPattern>` - Retrieve Shared Drives with names that match a pattern.
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
* `<PermissionMatch>* [<PermissionMatchAction>] pmselect` - Use permission matching to select Shared Drives; all ACLs are displayed for the selected Shared Drives
|
||||
@@ -927,12 +927,12 @@ gam redirect stdout ./DeleteSharedDrives.txt multiprocess redirect stderr stdout
|
||||
## Delete old empty Shared Drives
|
||||
```
|
||||
# Get a list of Shared Drives organizers for Shared Drives created before one year ago; alter date<-1y as required.
|
||||
gam config csv_output_row_filter "createdTime:date<-1y" redirect csv ./TeamDriveOrganizers.csv print shareddriveorganizers domainlist mydomain.com includetypes user oneorganizer shownoorganizerdrives
|
||||
gam config csv_output_row_filter "createdTime:date<-1y" redirect csv ./ShareddriveOrganizers.csv print shareddriveorganizers domainlist mydomain.com includetypes user oneorganizer shownoorganizerdrives
|
||||
|
||||
# Inspect shareddriveOrganizers.csv, you'll have to deal with Shared Drives with no organizer/manager
|
||||
|
||||
# Get old empty Shared Drives
|
||||
gam config num_threads 10 csv_input_row_filter "organizers:regex:^.+$" csv_output_row_filter "Total:count=0" redirect csv ./OldEmptySharedDrives.csv multiprocess redirect stderr - multiprocess csv ./TeamDriveOrganizers.csv gam user "~organizers" print filecounts select shareddriveid "~id" showsize
|
||||
gam config num_threads 10 csv_input_row_filter "organizers:regex:^.+$" csv_output_row_filter "Total:count=0" redirect csv ./OldEmptySharedDrives.csv multiprocess redirect stderr - multiprocess csv ./ShareddriveOrganizers.csv gam user "~organizers" print filecounts select shareddriveid "~id" showsize
|
||||
|
||||
# Inspect OldEmptySharedDrives.csv, if you're confident of the results, proceed
|
||||
|
||||
|
||||
@@ -145,40 +145,8 @@ The `quotechar <Character>` option allows you to choose an alternate quote chara
|
||||
## Transfer calendar ownership
|
||||
|
||||
You can transfer ownership of calendars from one user to another; only non-primary calendars owned by the source user can be transferred.
|
||||
```
|
||||
gam <UserTypeEntity> transfer calendars|seccals <UserItem> [<UserCalendarEntity>]
|
||||
[keepuser | (retainrole <CalendarACLRole>)] [sendnotifications <Boolean>]
|
||||
[noretentionmessages]
|
||||
[<CalendarSettings>] [append description|location|summary] [noupdatemessages]
|
||||
[deletefromoldowner] [addtonewowner <CalendarAttribute>*] [nolistmessages]
|
||||
```
|
||||
If `<UserCalendarEntity>` is not specified, all of a user's owned secondary calendars will be transferrdd.
|
||||
|
||||
By default, the users in `<UserTypeEntity>` retain no role in the transferred calendars.
|
||||
* `keepuser` - The users in `<UserTypeEntity>` retain their ownership.
|
||||
* `retainrole <CalendarACLRole>` - The users in `<UserTypeEntity>` retain the specified role.
|
||||
* `noretentionmessages` - Suppress the original owner role retention messages.
|
||||
This capability is no longer available, see: https://developers.google.com/workspace/calendar/release-notes#October_27_2025
|
||||
|
||||
By default, when you add or update a calendar ACL, a notification is sent to the affected users; use `sendnotifications false` to suppress sending the notifications.
|
||||
Data ownership can be transferred in the Google Calendar UI.
|
||||
|
||||
You can update calendar settings as part of the transfer. In description, location and summary, #email#, #user# and #username# will be replaced
|
||||
by the original owner's full email address or just the name portion; #timestamp# will be replaced by the current date and time.
|
||||
* `<CalendarSettings>` - The value specified will replace the existing value.
|
||||
* `append description|location|summary` - The specified <CalendarSettings> value will be appended to the existing value.
|
||||
* `noupdatemessages` - Suppress the settings update messages.
|
||||
|
||||
You can manipulate the old and new owner's calendar lists.
|
||||
* `deletefromoldowner` - Delete the calendar from the old owner's calendar list
|
||||
* `addtonewowner <CalendarAttribute>*` - Add the calendar to the new owner's calendar list; optionally specify attributes
|
||||
* `nolistmessages` - Suppress the calendar list add/delete messages.
|
||||
|
||||
### Example
|
||||
Transfer a secondary calendar from oldowner to newowner. Remove the calendar from the old owner's calendar list and add to the new owner's calendar list.
|
||||
```
|
||||
gam user oldowner@domain.com transfer calendars newowner@domain.com c_aaa123zzz@group.calendar.google.com removefromoldowner addtonewowner
|
||||
```
|
||||
|
||||
Transfer ownership of all non-primary calendars from oldowner to newowner; append a message to the calendar description noting the old owner and the time of transfer.
|
||||
```
|
||||
gam user oldowner@domain.com transfer calendars newowner@domain.com minaccessrole owner description "(Transferred from #user# on #timestamp#)" append description
|
||||
```
|
||||
|
||||
@@ -114,6 +114,8 @@
|
||||
<CourseState> ::= active|archived|provisioned|declined
|
||||
<CourseStateList> ::= all|"<CourseState>(,<CourseState>)*"
|
||||
<iCalUID> ::= <String>
|
||||
<MeetID> ::= <String>
|
||||
Must match this Python Regular Expression: [a-z]{3}-[a-z]{4}-[a-z]{3}
|
||||
<ResourceID> ::= <String>
|
||||
<ResourceIDList> ::= "<ResourceID>(,<ResourceID>)*"
|
||||
<UniqueID> ::= id:<String>
|
||||
@@ -215,7 +217,8 @@
|
||||
endtimeunspecified|
|
||||
extendedproperties|
|
||||
eventtype|
|
||||
<EventFocusTimePropertiesSubfieldName>
|
||||
focustimeproperties|
|
||||
<EventFocusTimePropertiesSubfieldName>|
|
||||
gadget|
|
||||
guestscaninviteothers|
|
||||
guestscanmodify|
|
||||
@@ -229,7 +232,8 @@
|
||||
organizer|
|
||||
<EventOrganizerSubfieldName>|
|
||||
originalstart|originalstarttime|
|
||||
<EventOutOfOfficePropertiesSubfieldName>
|
||||
outofofficeproperties|
|
||||
<EventOutOfOfficePropertiesSubfieldName>|
|
||||
privatecopy|
|
||||
recurrence|
|
||||
recurringeventid|
|
||||
@@ -320,6 +324,7 @@
|
||||
(birthday <Date>)|
|
||||
(color <EventColorName>)|
|
||||
(colorindex|colorid <EventColorIndex>)|
|
||||
(conferencedata meet <MeetID>)|
|
||||
(description <String>)|
|
||||
(end|endtime (allday <Date>)|<Time>)|
|
||||
(guestscaninviteothers <Boolean>)|
|
||||
@@ -591,11 +596,16 @@ Use `jsonattendees file ./attendees.json` in `create/update event`.
|
||||
|
||||
## Delete selected calendar events
|
||||
```
|
||||
gam <UserTypeEntity> delete events <UserCalendarEntity> [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> purge events <UserCalendarEntity> [<EventEntity>] [doit] [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> delete events <UserCalendarEntity> [<EventEntity>]
|
||||
[batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
gam <UserTypeEntity> purge events <UserCalendarEntity> [<EventEntity>]
|
||||
[batchsize <Integer>] [doit] [<EventNotificationAttribute>]
|
||||
```
|
||||
If `<EventEntity>` is not specified, all events in `<UserCalendarEntity>` are selected. This is not typically used.
|
||||
|
||||
By default, each event is deleted in a separate API call, use `batchsize` with an integer between 1 and 1000
|
||||
to delete the events in batches.
|
||||
|
||||
No events are deleted unless you specify the `doit` option; omit `doit` to verify that you properly selected the events to delete.
|
||||
|
||||
When events are deleted from a calendar, they are moved to the calendar's trash and are only permanently deleted (purged) after 30 days.
|
||||
@@ -671,9 +681,10 @@ By default, Gam displays event details, use `countsonly` to display only the num
|
||||
|
||||
```
|
||||
gam <UserTypeEntity> print events <UserCalendarEntity> [<EventEntity>] <EventDisplayProperty>*
|
||||
[fields <EventFieldNameList>] [showdayofweek]
|
||||
[fields <EventFieldNameList>] [showdayofweek] [attendeeslist]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
[eventrowfilter] [countsonly|(formatjson [quotechar <Character>])] [todrive <ToDriveAttribute>*]
|
||||
[eventrowfilter]
|
||||
[countsonly|(formatjson [quotechar <Character>])] [todrive <ToDriveAttribute>*]
|
||||
```
|
||||
In `<EventEntity>`, any `<EventSelectProperty>` options must precede all other options.
|
||||
|
||||
@@ -684,6 +695,10 @@ option `singleevents` to display all instances of a recurring event.
|
||||
|
||||
`showdayofweek` displays columns `start.dayOfWeek` and `end.dayOfWeek` when event start and end times are displayed.
|
||||
|
||||
By default, each attendee is displayed in a separate column; `attendeeslist` causes GAM to display
|
||||
the attendee email addresses in a single column `attendeesList`; no attendee details are displayed.
|
||||
The email addresses are separated by `csv_output_field_delimiter` from `gam.cfg`.
|
||||
|
||||
Add additional columns of data from the command line to the output after the calendarId.
|
||||
* `addcsvdata <FieldName> <String>`
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Users - Calendars
|
||||
Users - Calendars
|
||||
- [API documentation](#api-documentation)
|
||||
- [Definitions](#definitions)
|
||||
- [Calendar colors](#calendar-colors)
|
||||
@@ -74,8 +74,8 @@
|
||||
[coursestates <CourseStateList>])|
|
||||
(resource <ResourceID>)|
|
||||
(resources <ResourceIDList>)|
|
||||
((calendars <CalendarList>) | <FileSelector> | <CSVFileSelector> |
|
||||
<CSVkmdSelector> | <CSVDataSelector>)
|
||||
(calendars <CalendarList> | <FileSelector> | <CSVFileSelector> |
|
||||
<CSVkmdSelector> | <CSVDataSelector>)
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Items
|
||||
|
||||
<UserCalendarEntity> ::=
|
||||
@@ -90,8 +90,8 @@
|
||||
[coursestates <CourseStateList>])|
|
||||
(resource <ResourceID>)|
|
||||
(resources <ResourceIDList>)|
|
||||
((calendars <CalendarList>) | <FileSelector> | <CSVFileSelector> |
|
||||
<CSVkmdSelector> | <CSVDataSelector>)|
|
||||
(calendars <CalendarList> | <FileSelector> | <CSVFileSelector> |
|
||||
<CSVkmdSelector> | <CSVDataSelector>)|
|
||||
<CalendarSelectProperty>*
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Items
|
||||
|
||||
@@ -101,6 +101,7 @@
|
||||
defaulteventlength|
|
||||
format24hourtime|
|
||||
hideinvitations|
|
||||
hideinvitationssetting|
|
||||
hideweekends|
|
||||
locale|
|
||||
remindonrespondedeventsonly|
|
||||
|
||||
@@ -7,6 +7,10 @@
|
||||
- [Chat Space Permissions](#chat-space-permissions)
|
||||
- [Manage Chat Spaces](#manage-chat-spaces)
|
||||
- [Display Chat Spaces](#display-chat-spaces)
|
||||
- [Manage Chat User Sections](#manage-chat-user-sections)
|
||||
- [Display Chat User Sections](#display-chat-user-sections)
|
||||
- [Manage Chat User Section Items](#manage-chat-user-section-items)
|
||||
- [Display Chat User Section Items](#display-chat-user-section-items)
|
||||
- [UI API member role mapping](#ui-api-mwmber-role-mapping)
|
||||
- [Manage Chat Members](#manage-chat-members)
|
||||
- [Display Chat Members](#display-chat-members)
|
||||
@@ -30,7 +34,12 @@ gam user user@domain.com update serviceaccount
|
||||
[*] 8) Chat API - Spaces Admin (supports readonly)
|
||||
[*] 9) Chat API - Spaces Delete
|
||||
[*] 10) Chat API - Spaces Delete Admin
|
||||
[*] 11) Chat API - User Sections (supports readonly)
|
||||
|
||||
```
|
||||
`Chat API - User Sections` is in Developer Preview; you must have a the following variables set in `gam.cfg` to use these commands.
|
||||
* `developer_preview_apis = chat`
|
||||
* `developer_preview_api_key = <String>`
|
||||
|
||||
Added `use_chat_admin_access` Boolean variable to `gam.cfg`.
|
||||
```
|
||||
@@ -60,6 +69,7 @@ Google requires that you have a Chat Bot configured in order to use the Chat API
|
||||
* [Chat API - Members](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces.members/list)
|
||||
* [Chat API - Messages](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces.messages/list)
|
||||
* [Chat API - Events](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces.spaceEvents/list)
|
||||
* [Chat API - User Sections](https://developers.google.com/workspace/chat/api/reference/rest/v1/users.sections)
|
||||
* [Apps in Google Chat](https://support.google.com/chat/answer/7655820)
|
||||
* [Manage customemoji permissions](https://support.google.com/a/answer/12850085)
|
||||
* [Manage Spaces in Admin Console](https://support.google.com/a/answer/13369245)
|
||||
@@ -96,6 +106,8 @@ Google requires that you have a Chat Bot configured in order to use the Chat API
|
||||
<ChatMember> ::= spaces/<String>/members/<String>
|
||||
<ChatMemberList> ::= "<ChatMember>(,<ChatMember>)*"
|
||||
<ChatMessage> ::= spaces/<String>/messages/<String>
|
||||
<ChatSection> ::= users/<String>/sections/<String> | sections/<String> | section <String>
|
||||
<ChatSectionItem> ::= users/<String>/sections/<String>/items/<String> | sections/<String>/items/<String>
|
||||
<ChatSpace> ::= spaces/<String> | space <String> | space spaces/<String>
|
||||
<ChatThread> ::= spaces/<String>/threads/<String>
|
||||
<ChatSpaceType> ::=
|
||||
@@ -422,6 +434,83 @@ When using the `formatjson` option, double quotes are used extensively in the da
|
||||
The `quotechar <Character>` option allows you to choose an alternate quote character, single quote for instance, that makes for readable/processable output.
|
||||
`quotechar` defaults to `gam.cfg/csv_output_quote_char`. When uploading CSV files to Google, double quote `"` should be used.
|
||||
|
||||
## Manage Chat User Sections
|
||||
### Create a user's chat section
|
||||
```
|
||||
gam <UserTypeEntity> create chatsection
|
||||
displayname <String>
|
||||
[formatjson|returnidonly]
|
||||
```
|
||||
|
||||
### Update a user's chat section
|
||||
```
|
||||
gam <UserTypeEntity> update chatsection <ChatSection>
|
||||
[displayname <String>]
|
||||
[(sortorder <Integer>)|(position start|end)]
|
||||
[formatjson]
|
||||
```
|
||||
|
||||
### Delete a user's chat section
|
||||
```
|
||||
gam <UserTypeEntity> delete chatsection <ChatSection>
|
||||
```
|
||||
|
||||
## Display Chat User Sections
|
||||
### Display information about all of a user's chat sections
|
||||
```
|
||||
gam <UserTypeEntity> show chatsections
|
||||
[formatjson]
|
||||
```
|
||||
By default, Gam displays the information as an indented list of keys and values.
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
```
|
||||
gam <UserTypeEntity> print chatsections [todrive <ToDriveAttribute>*]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
The `quotechar <Character>` option allows you to choose an alternate quote character, single quote for instance, that makes for readable/processable output.
|
||||
`quotechar` defaults to `gam.cfg/csv_output_quote_char`. When uploading CSV files to Google, double quote `"` should be used.
|
||||
|
||||
## Manage Chat User Section Items
|
||||
### Move a user's chat section item to a different chat section
|
||||
```
|
||||
gam <UserTypeEntity> move chatsectionitem <ChatSectionItem> to <ChatSection>
|
||||
```
|
||||
|
||||
## Display Chat User Section Items
|
||||
### Display information about a user's chat section items
|
||||
```
|
||||
gam <UserTypeEntity> show chatsectionitems <ChatSection>
|
||||
[space <ChatSpace>]
|
||||
[formatjson]
|
||||
```
|
||||
You can search for a chat section that contains a chat space with:
|
||||
`show chatsectionitems sections/- space <ChatSpace>`
|
||||
|
||||
By default, Gam displays the information as an indented list of keys and values.
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
```
|
||||
gam <UserTypeEntity> print chatsectionitems <ChatSection> [todrive <ToDriveAttribute>*]
|
||||
[space <ChatSpace>]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
You can search for a chat section that contains a chat space with:
|
||||
`print chatsectionitems sections/- space <ChatSpace>`
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
The `quotechar <Character>` option allows you to choose an alternate quote character, single quote for instance, that makes for readable/processable output.
|
||||
`quotechar` defaults to `gam.cfg/csv_output_quote_char`. When uploading CSV files to Google, double quote `"` should be used.
|
||||
|
||||
## UI API member role mapping
|
||||
GAM uses the Chat UI role names.
|
||||
|
||||
|
||||
@@ -18,8 +18,8 @@
|
||||
<SharedDriveID> ::= <String>
|
||||
<SharedDriveName> ::= <String>
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveID>|(teamdriveid <SharedDriveID>)|(teamdriveid:<SharedDriveID>)|
|
||||
(teamdrive <SharedDriveName>)|(teamdrive:<SharedDriveName>)
|
||||
<SharedDriveID>|(shareddriveid <SharedDriveID>)|(shareddriveid:<SharedDriveID>)|
|
||||
(shareddrive <SharedDriveName>)|(shareddrive:<SharedDriveName>)
|
||||
```
|
||||
## Display empty folders
|
||||
```
|
||||
|
||||
@@ -41,6 +41,11 @@
|
||||
<RESearchPattern> ::= <RegularExpression>
|
||||
<RESubstitution> ::= <String>>
|
||||
|
||||
<MimeTypeName> ::= application|audio|font|image|message|model|multipart|text|video
|
||||
<MimeTypeNameList> ::= "<MimeTypeName>(,<MimeTypeName>)*"
|
||||
<MimeType> ::= <MimeTypeName>/<String>
|
||||
<MimeTypeList> ::= "<MimeType>(,<MimeType>)*"
|
||||
|
||||
<CorporaAttribute> ::= allteamdrives|domain|onlyteamdrives|user
|
||||
<DomainName> ::= <String>(.<String>)+
|
||||
<DomainNameList> ::= "<DomainName>(,<DomainName>)*"
|
||||
@@ -63,10 +68,10 @@
|
||||
(parentid <DriveFolderID>)|
|
||||
(parentname <DriveFolderName>)|
|
||||
(anyownerparentname <DriveFolderName>)|
|
||||
(teamdriveparentid <DriveFolderID>)|
|
||||
(teamdriveparent <SharedDriveName>)|
|
||||
(teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>)|
|
||||
(teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>)
|
||||
(shareddriveparentid <DriveFolderID>)|
|
||||
(shareddriveparent <SharedDriveName>)|
|
||||
(shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>)|
|
||||
(shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>)
|
||||
|
||||
<DriveFileCopyAttribute> ::=
|
||||
(contentrestrictions readonly false)|
|
||||
@@ -99,8 +104,14 @@ gam <UserTypeEntity> copy drivefile <DriveFileEntity>
|
||||
<DriveFileCopyAttribute>*
|
||||
[skipids <DriveFileEntity>]
|
||||
[copysubfiles [<Boolean>]] [filenamematchpattern <REMatchPattern>]
|
||||
[filemimetype [not] <MimeTypeList>]
|
||||
[copysubfilesownedby any|me|others]
|
||||
[filemimetype [not] <MimeTypeList>] [filemimetype category <MimeTypeNameList>]
|
||||
[copysubfilesownedby
|
||||
any|me|others|
|
||||
users <EmailAddressList>|
|
||||
notusers <EmailAddressList>|
|
||||
regex <REMatchPattern>|
|
||||
notregex <REMatchPattern>]
|
||||
[([start|starttime <Date>|<Time>] [end|endtime <Date>|<Time>])|(range <Date>|<Time> <Date>|<Time>)]|
|
||||
[copysubfolders [<Boolean>]] [foldernamematchpattern <REMatchPattern>]
|
||||
[copysubshortcuts [<Boolean>]] [shortcutnamematchpattern <REMatchPattern>]
|
||||
[duplicatefiles overwriteolder|overwriteall|duplicatename|uniquename|skip]
|
||||
@@ -172,14 +183,17 @@ You can specify whether sub files, folders and shortcuts are copied. If sub fold
|
||||
* `copysubshortcuts false` - Sub shortcuts are not copied
|
||||
* `copysubshortcuts [true]` - Sub shortcuts are copied; this is the default
|
||||
|
||||
By default, GAM displays a message referencing files and folders not selected for copying by the options above.
|
||||
* `suppressnotselectedmessages false` - Do not suppress these messages; this is the default
|
||||
* `suppressnotselectedmessages [true]` - Suppress these messages
|
||||
|
||||
### By default, when copying sub files, all files, regardless of MIME type, are copied.
|
||||
You can specify restrictions on the MIME types to be copied.
|
||||
* `filemimetypes <MimeTypeList>` - Copy sub files with the specified MIME types
|
||||
* `filemimetypes not <MimeTypeList>` - Copy sub files with MIME types other than those specified
|
||||
* `filemimetypes category <MimeTypeNameList>` - Copy sub files with the specified MIME type categories
|
||||
|
||||
### By default, when copying sub files, all files, regardless of their `modifiedTime`, are copied.
|
||||
You can specify restrictions on the `modifiedTime` to be copied.
|
||||
* `start|starttime <Date>|<Time>` - If specified, `modifiedTime` must be >= the value
|
||||
* `end|endtime <Date>|<Time>` - If specified, `modifiedTime` must be <= the value
|
||||
* `range <Date>|<Time> <Date>|<Time>` - first value <= `modifiedTime` <= second value
|
||||
|
||||
### By default, when copying sub files, folders and shortcuts, all are copied.
|
||||
You can specify `<REMatchPattern>` patterns that limit the items copied based on their name.
|
||||
@@ -188,9 +202,17 @@ You can specify `<REMatchPattern>` patterns that limit the items copied based on
|
||||
* `shortcutnamematchpattern <REMatchPattern>` - Only shortcuts whose name matches `<REMatchPattern>` are copied
|
||||
|
||||
### By default, when copying sub files, all files, regardless of ownership, are copied.
|
||||
* `copysubfilesownedby any` - All files, regardless of ownership, are copied.
|
||||
* `copysubfilesownedby any` - All files, regardless of ownership, are copied; this is the default.
|
||||
* `copysubfilesownedby me` - Only files owned by `<UserTypeEntity>` are copied.
|
||||
* `copysubfilesownedby others` - Only files not owned by `<UserTypeEntity>` are copied.
|
||||
* `copysubfilesownedby users <EmailAddressList>` - Only files owned by users in `<EmailAddressList>` are copied.
|
||||
* `copysubfilesownedby notusers <EmailAddressList>` - Only files not owned by users in `<EmailAddressList>` are copied.
|
||||
* `copysubfilesownedby regex <REMatchPattern>` - Only files owned by users whose email addresses match `<REMatchPattern>` are copied.
|
||||
* `copysubfilesownedby notregex <REMatchPattern>` - Only files owned by users whose email addresses do not match `<REMatchPattern>` are copied.
|
||||
|
||||
### By default, GAM displays a message referencing files and folders not selected for copying by the options above.
|
||||
* `suppressnotselectedmessages false` - Do not suppress these messages; this is the default
|
||||
* `suppressnotselectedmessages [true]` - Suppress these messages
|
||||
|
||||
### Specify a new name for the file/folder
|
||||
* `newfilename <DriveFileName>` - The copied file/folder will be named `<DriveFileName>`
|
||||
@@ -209,10 +231,10 @@ and "Template" is replaced by "NewCustomer" in all copied sub files and folders
|
||||
* `parentid <DriveFolderID>` - The target folder is identified by `<DriveFolderID>` which must be writable by `<UserTypeEntity>`.
|
||||
* `parentname <DriveFolderName>` - A search is performed for a folder named `<DriveFolderName>` owned by `<UserTypeEntity>`.
|
||||
* `anyownerparentname <DriveFolderName>` - A search is performed for a folder named `<DriveFolderName>` owned by any user but must be writable by `<UserTypeEntity>`.
|
||||
* `teamdriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specific Shared Drive folder.
|
||||
* `teamdriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* `shareddriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specific Shared Drive folder.
|
||||
* `shareddriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* If none of the parent options are specified, the copied file/folder will be located in the source folder.
|
||||
|
||||
### Duplicate files
|
||||
@@ -392,15 +414,15 @@ Specify the target location on the Shared Drive, either the ID of the Shared Dri
|
||||
|
||||
Files/folders in root of My Drive will be merged into `<DriveFolderID>`
|
||||
```
|
||||
gam user user@domain.com copy drivefile root recursive teamdriveparentid <DriveFolderID> mergewithparent true
|
||||
gam user user@domain.com copy drivefile root recursive shareddriveparentid <DriveFolderID> mergewithparent true
|
||||
```
|
||||
Files/folders in root of My Drive will be in a new folder named `My Drive` created in `<DriveFolderID>`
|
||||
```
|
||||
gam user user@domain.com copy drivefile root recursive teamdriveparentid <DriveFolderID> mergewithparent false
|
||||
gam user user@domain.com copy drivefile root recursive shareddriveparentid <DriveFolderID> mergewithparent false
|
||||
```
|
||||
Files/folders in root of My Drive will be in a new folder named `<String>` created in `<DriveFolderID>`
|
||||
```
|
||||
gam user user@domain.com copy drivefile root recursive teamdriveparentid <SharedDriveID> mergewithparent false newfilename <String>
|
||||
gam user user@domain.com copy drivefile root recursive shareddriveparentid <SharedDriveID> mergewithparent false newfilename <String>
|
||||
```
|
||||
|
||||
### Copy content of a Shared Drive to another Shared Drive
|
||||
@@ -416,7 +438,7 @@ The example is assuming that the target drive is empty.
|
||||
* Non-inherited sub folder permissions are copied.
|
||||
* Non-inherited file permissions are copied.
|
||||
```
|
||||
gam user user@domain.com copy drivefile teamdriveid 0AC_1AB teamdriveparentid 0AE_9ZX mergewithparent recursive
|
||||
gam user user@domain.com copy drivefile shareddriveid 0AC_1AB shareddriveparentid 0AE_9ZX mergewithparent recursive
|
||||
copymergewithparentfolderpermissions true
|
||||
copytopfolderinheritedpermissions false
|
||||
copytopfoldernoninheritedpermissions always
|
||||
@@ -436,7 +458,7 @@ Suppose that the source drive has been updated and you want to refresh the targe
|
||||
* Non-inherited file permissions are copied.
|
||||
* Files and folders that have been deleted from the source drive will remain on the target drive
|
||||
```
|
||||
gam user user@domain.com copy drivefile teamdriveid 0AC_1AB teamdriveparentid 0AE_9ZX mergewithparent recursive
|
||||
gam user user@domain.com copy drivefile shareddriveid 0AC_1AB shareddriveparentid 0AE_9ZX mergewithparent recursive
|
||||
copymergewithparentfolderpermissions true
|
||||
copytopfolderinheritedpermissions false
|
||||
copytopfoldernoninheritedpermissions syncallfolders
|
||||
@@ -456,7 +478,7 @@ gam redirect csv ./TopSDItems.csv user user@domain.com print filelist select 0AC
|
||||
```
|
||||
Copy the top level items to target Shared Drive; append desired permission options
|
||||
```
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive teamdriveparentid 0AE_9ZX
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive shareddriveparentid 0AE_9ZX
|
||||
```
|
||||
|
||||
### Copy content of a source Shared Drive folder to a target Shared Drive with parallel Processing
|
||||
@@ -466,31 +488,31 @@ gam redirect csv ./TopSDItems.csv user user@domain.com print filelist select 1Bx
|
||||
```
|
||||
Create a folder on target Shared Drive with ID 0AE_9ZX, replace "New Folder Name" as desired.
|
||||
```
|
||||
gam user user@domain.com create drivefile mimetype gfolder teamdriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly
|
||||
gam user user@domain.com create drivefile mimetype gfolder shareddriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly
|
||||
```
|
||||
Copy the folder top level items to target Shared Drive folder, assume ID 2CY-45G was returned in previous step
|
||||
```
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive teamdriveparentid 2CY-45G
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive shareddriveparentid 2CY-45G
|
||||
```
|
||||
You can script the steps:
|
||||
|
||||
Linux/MacOS
|
||||
```
|
||||
gam redirect csv ./TopSDItems.csv user user@domain.com print filelist select 1Bx-8W3 fields id,name,mimetype depth 0
|
||||
targetFolderId=$(gam user user@domain.com create drivefile mimetype gfolder teamdriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly)
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive teamdriveparentid $targetFolderId
|
||||
targetFolderId=$(gam user user@domain.com create drivefile mimetype gfolder shareddriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly)
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive shareddriveparentid $targetFolderId
|
||||
```
|
||||
Windows PowerShell
|
||||
```
|
||||
gam redirect csv ./TopSDItems.csv user user@domain.com print filelist select 1Bx-8W3 fields id,name,mimetype depth 0
|
||||
$targetFolderId = & gam user user@domain.com create drivefile mimetype gfolder teamdriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive teamdriveparentid $targetFolderId
|
||||
$targetFolderId = & gam user user@domain.com create drivefile mimetype gfolder shareddriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive shareddriveparentid $targetFolderId
|
||||
```
|
||||
Windows Command Prompt
|
||||
```
|
||||
gam redirect csv ./TopSDItems.csv user user@domain.com print filelist select 1Bx-8W3 fields id,name,mimetype depth 0
|
||||
for /f "delims=" %a in ('gam user user@domain.com create drivefile mimetype gfolder teamdriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly') do set taregtFolderId=%a
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive teamdriveparentid %targetFolderId%
|
||||
for /f "delims=" %a in ('gam user user@domain.com create drivefile mimetype gfolder shareddriveparentid 0AE-9ZX drivefilename "New Folder Name" returnidonly') do set taregtFolderId=%a
|
||||
gam redirect stdout ./CopySharedDrive.txt multiprocess redirect stderr stdout csv TopSDItems.csv gam user user@domain.com copy drivefile "~id" recursive shareddriveparentid %targetFolderId%
|
||||
```
|
||||
|
||||
## Move files and folders
|
||||
@@ -592,10 +614,10 @@ This is the default mode.
|
||||
* `parentid <DriveFolderID>` - The target folder is identified by `<DriveFolderID>` which must be writable by `<UserTypeEntity>`.
|
||||
* `parentname <DriveFolderName>` - A search is performed for a folder named `<DriveFolderName>` owned by `<UserTypeEntity>`.
|
||||
* `anyownerparentname <DriveFolderName>` - A search is performed for a folder named `<DriveFolderName>` owned by any user but must be writable by `<UserTypeEntity>`.
|
||||
* `teamdriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specific Shared Drive folder.
|
||||
* `teamdriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* `shareddriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specific Shared Drive folder.
|
||||
* `shareddriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* If none of the parent options are specified, the moved file/folder will be located in the source folder.
|
||||
|
||||
### Duplicate files
|
||||
@@ -739,14 +761,14 @@ The following command will change the parents of the top level files and folders
|
||||
|
||||
* No permissions are processed.
|
||||
```
|
||||
gam user user@domain.com move drivefile teamdriveid 0AC_1AB teamdriveparentid 0AE_9ZX mergewithparent
|
||||
gam user user@domain.com move drivefile shareddriveid 0AC_1AB shareddriveparentid 0AE_9ZX mergewithparent
|
||||
```
|
||||
|
||||
If you want the source Shared Drive with ID 0AC_1AB to be contained in a top level folder of the target Shared Drive with ID 0AE_9ZX, omit the `mergewithparent` argument.
|
||||
The folder on the target Shared Drive will have the same name as the name of the source Shared Drive; use the `newfilename <DriveFileName>` to use a different name.
|
||||
```
|
||||
gam user user@domain.com move drivefile teamdriveid 0AC_1AB teamdriveparentid 0AE_9ZX
|
||||
gam user user@domain.com move drivefile teamdriveid 0AC_1AB teamdriveparentid 0AE_9ZX newfilename "Copy of source Shared Drive"
|
||||
gam user user@domain.com move drivefile shareddriveid 0AC_1AB shareddriveparentid 0AE_9ZX
|
||||
gam user user@domain.com move drivefile shareddriveid 0AC_1AB shareddriveparentid 0AE_9ZX newfilename "Copy of source Shared Drive"
|
||||
```
|
||||
|
||||
### Inter-workspace moves
|
||||
@@ -756,7 +778,7 @@ Due to a restructuring, you want to move data from Shared Drive A in domaina.com
|
||||
* `user@domaina.com` is a manager of both Shared Drives.
|
||||
|
||||
```
|
||||
$ gam user user@domaina move drivefile teamdriveid <SharedDriveAID> teamdriveparentid <SharedDriveBID> mergewithparent
|
||||
$ gam user user@domaina move drivefile shareddriveid <SharedDriveAID> shareddriveparentid <SharedDriveBID> mergewithparent
|
||||
User: user@domaina.com, Move 1 Drive File/Folder
|
||||
User: user@domaina.com, Drive Folder: Shared Drive A(<SharedDriveAID>), Move(Merge) contents with Drive Folder: Shared Drive B(<SharedDriveBID>)
|
||||
User: user@domaina.com, Drive File: Filename(<FileID>), Move Failed: Bad Request. User message: "shareOutNotPermitted"
|
||||
@@ -772,13 +794,13 @@ The following command will change the parents of the top level files and folders
|
||||
|
||||
* No permissions are processed.
|
||||
```
|
||||
gam user user@domain.com move drivefile teamdriveid 0AC_1AB parentid root mergewithparent
|
||||
gam user user@domain.com move drivefile shareddriveid 0AC_1AB parentid root mergewithparent
|
||||
```
|
||||
|
||||
If you want the contents of Shared Drive with ID 0AC_1AB to be contained in a top level folder of the My Drive, omit the `mergewithparent` argument.
|
||||
The folder on the My Drive will have the same name as the name of the Shared Drive; use the `newfilename <DriveFileName>` to use a different name.
|
||||
```
|
||||
gam user user@domain.com move drivefile teamdriveid 0AC_1AB parentid root
|
||||
gam user user@domain.com move drivefile teamdriveid 0AC_1AB parentid root newfilename "Copy of Shared Drive"
|
||||
gam user user@domain.com move drivefile shareddriveid 0AC_1AB parentid root
|
||||
gam user user@domain.com move drivefile shareddriveid 0AC_1AB parentid root newfilename "Copy of Shared Drive"
|
||||
```
|
||||
|
||||
|
||||
@@ -65,9 +65,9 @@
|
||||
|
||||
<SharedDriveID> ::= <String>
|
||||
<SharedDriveName> ::= <String>
|
||||
<SharedDriveIDEntity> ::= (teamdriveid <SharedDriveID>) | (teamdriveid:<SharedDriveID>)
|
||||
<SharedDriveNameEntity> ::= (teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (teamdrivefilename <DriveFileName>) | (teamdrivefilename:<DriveFileName>)
|
||||
<SharedDriveIDEntity> ::= (shareddriveid <SharedDriveID>) | (shareddriveid:<SharedDriveID>)
|
||||
<SharedDriveNameEntity> ::= (shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (shareddrivefilename <DriveFileName>) | (shareddrivefilename:<DriveFileName>)
|
||||
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveIDEntity> |
|
||||
@@ -315,8 +315,8 @@
|
||||
size|
|
||||
spaces|
|
||||
starred|
|
||||
teamdriveid|
|
||||
teamdrivename|
|
||||
shareddriveid|
|
||||
shareddrivename|
|
||||
thumbnaillink|
|
||||
thumbnailversion|
|
||||
title|
|
||||
@@ -430,6 +430,7 @@ gam <UserTypeEntity> show fileinfo <DriveFileEntity>
|
||||
(orderby <DriveFileOrderByFieldName> [ascending|descending])*
|
||||
[showdrivename] [showshareddrivepermissions]
|
||||
[(showlabels details|ids)|(includelabels <ClassificationLabelIDList>)]
|
||||
[includepermissionsforview published]
|
||||
[showparentsidsaslist] [followshortcuts [<Boolean>]]
|
||||
[stripcrsfromname]
|
||||
[formatjson]
|
||||
@@ -440,6 +441,7 @@ gam <UserTypeEntity> info drivefile <DriveFileEntity>
|
||||
(orderby <DriveFileOrderByFieldName> [ascending|descending])*
|
||||
[showdrivename] [showshareddrivepermissions]
|
||||
[(showlabels details|ids)|(includelabels <ClassificationLabelIDList>)]
|
||||
[includepermissionsforview published]
|
||||
[showparentsidsaslist] [followshortcuts [<Boolean>]]
|
||||
[stripcrsfromname]
|
||||
[formatjson]
|
||||
@@ -617,8 +619,10 @@ This option is not available for `print|show filetree`.
|
||||
```
|
||||
((query <QueryDriveFile>) | (fullquery <QueryDriveFile>) | <DriveFileQueryShortcut>) (querytime<String> <Time>)*
|
||||
```
|
||||
GAM initializes the query to `'me' in owners`.
|
||||
|
||||
* `query "xxx"` - ` and xxx` is appended to the current query; you can repeat the query argument to build up a longer query.
|
||||
* `fullquery "xxx"` - The query is set to `xxx` eliminating the initial `'me' in owners`.
|
||||
* `fullquery "xxx"` - The query is set to `xxx` eliminating the initial `'me' in owners`. You must also use `showownedby any|others` as desired.
|
||||
* `<DriveFileQueryShortcut>` - Predefined queries
|
||||
|
||||
Use the `querytime<String> <Time>` option to allow times, usually relative, to be substituted into the `query <QueryDriveFile>` option.
|
||||
@@ -752,7 +756,7 @@ The option `showlastmodification` displays the following fields:
|
||||
`lastModifiedFileId,lastModifiedFileName,lastModifiedFileMimeType,lastModifiedFilePath,lastModifyingUser,lastModifiedTime`;
|
||||
these are for the most recently modified file.
|
||||
|
||||
For print filecouts, add additional columns of data from the command line to the output:
|
||||
For print filecounts, add additional columns of data from the command line to the output:
|
||||
* `addcsvdata <FieldName> <String>` - Add additional columns of data from the command line to the output
|
||||
|
||||
See [Select files for Display file counts, list, tree](#select-files-for-display-file-counts-list-tree)
|
||||
@@ -880,11 +884,11 @@ Print or show the share type counts of a user's files. These fields are displaye
|
||||
```
|
||||
gam <UserTypeEntity> print filesharecounts [todrive <ToDriveAttribute>*]
|
||||
[excludetrashed]
|
||||
[internaldomains <DomainNameList>]
|
||||
[internaldomains all|primary|<DomainNameList>]
|
||||
[summary none|only|plus] [summaryuser <String>]
|
||||
gam <UserTypeEntity> show filesharecounts
|
||||
[excludetrashed]
|
||||
[internaldomains <DomainNameList>]
|
||||
[internaldomains all|primary|<DomainNameList>]
|
||||
[summary none|only|plus] [summaryuser <String>]
|
||||
```
|
||||
|
||||
@@ -892,8 +896,10 @@ By default, print|show filesharecounts displays share type counts of all files o
|
||||
|
||||
Use the `excludetrashed` option to suppress counting files in the trash.
|
||||
|
||||
By default, `internaldomains <DomainNameList>` defaults to your primary domain; if you have other domains that
|
||||
you consider internal, list all of them in `<DomainNameList>`.
|
||||
Which domains are considered internal domains:
|
||||
* `internaldomains all` - All of your workspace domains; this is the default
|
||||
* `internaldomains primary` - Your workspace primary domain
|
||||
* `internaldomains <DomainNameList>` - A list of domain names
|
||||
|
||||
By default, share type counts for individual users are displayed; the `summary` option offers alternatives
|
||||
that can display a summarization of share type counts across all users specified in the command.
|
||||
@@ -1100,10 +1106,11 @@ gam <UserTypeEntity> print|show filelist [todrive <ToDriveAttribute>*]
|
||||
[allfields|<DriveFieldName>*|(fields <DriveFieldNameList>)]
|
||||
[showdrivename] [showshareddrivepermissions]
|
||||
[(showlabels details|ids)|(includelabels <ClassificationLabelIDList>)]
|
||||
[includepermissionsforview published]
|
||||
[showparentsidsaslist] [showpermissionslast]
|
||||
(orderby <DriveFileOrderByFieldName> [ascending|descending])* [delimiter <Character>]
|
||||
[stripcrsfromname]
|
||||
(addcsvdata <FieldName> <String>)*
|
||||
(addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]]
|
||||
```
|
||||
By default, `print filelist` displays all files owned by the specified [`<UserTypeEntity>`](https://github.com/GAM-team/GAM/wiki/Collections-of-Users)
|
||||
@@ -1214,7 +1221,6 @@ If no query or select is performed, use these options to get file path informati
|
||||
* `filepath|fullpath` - For files and folders, display the full path(s) to them starting at the root (My Drive)
|
||||
* `addpathstojson` - When this option and `formatjson` are specified, the path information will be included in the
|
||||
JSON data rather than as additional columns
|
||||
* `addcsvdata <FieldName> <String>` - Add additional columns of data from the command line to the output
|
||||
|
||||
When used with `filepath` or `fullpath`, `showdepth` will display a `depth` column.
|
||||
Files/folders directly in `My Drive` are at depth 0, the depth increases by 1
|
||||
@@ -1308,9 +1314,15 @@ Use the `countsrowfilter` option to have GAM to apply `config csv_output_row_fil
|
||||
The `stripcrsfromname` option strips nulls, carriage returns and linefeeds from drive file names.
|
||||
This option is special purpose and will not generally be used.
|
||||
|
||||
Add additional columns of data from the command line to the output
|
||||
* `addcsvdata <FieldName> <String>` - Add additional columns of data from the command line to the output
|
||||
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
If `formatjson` and `addcsvdata` are specified, the option `includecsvdatainjson` causes GAM to add the
|
||||
additional field values to the JSON data.
|
||||
|
||||
By default, when writing CSV files, Gam uses a quote character of double quote `"`. The quote character is used to enclose columns that contain
|
||||
the quote character itself, the column delimiter (comma by default) and new-line characters. Any quote characters within the column are doubled.
|
||||
When using the `formatjson` option, double quotes are used extensively in the data resulting in hard to read/process output.
|
||||
|
||||
@@ -149,10 +149,10 @@
|
||||
(parentid <DriveFolderID>)|
|
||||
(parentname <DriveFolderName>)|
|
||||
(anyownerparentname <DriveFolderName>)|
|
||||
(teamdriveparentid <DriveFolderID>)|
|
||||
(teamdriveparent <SharedDriveName>)|
|
||||
(teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>)|
|
||||
(teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>)
|
||||
(shareddriveparentid <DriveFolderID>)|
|
||||
(shareddriveparent <SharedDriveName>)|
|
||||
(shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>)|
|
||||
(shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>)
|
||||
|
||||
<DriveFileCreateAttribute> ::=
|
||||
<DriveFileAttribute>|
|
||||
@@ -196,10 +196,10 @@ You can specify where the new file is to be located:
|
||||
* `parentid <DriveFolderID>` - Folder ID.
|
||||
* `parentname <DriveFolderName>` - Folder name; the folder must be owned by `<UserTypeEntity>`.
|
||||
* `anyownerparentname <DriveFolderName>` - Folder name; the folder can be owned by any user, `<UserTypeEntity>` must be able to write to the folder.
|
||||
* `teamdriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specfic Shared Drive folder.
|
||||
* `teamdriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* `shareddriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specfic Shared Drive folder.
|
||||
* `shareddriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* If none of the parent options are specified, the parent folder is the root folder.
|
||||
|
||||
By default, Google assigns the current time to the attributes `createdTime` and `modifiedTime`; you can assign your own values
|
||||
@@ -290,7 +290,7 @@ This will create a three column CSV file SharedDriveNamesIDs.csv with columns: U
|
||||
You are building student folders on a Shared Drive as an admin and want to add ACLs to the folders
|
||||
allowing the student write access and you want a shortcut on the student's My Drive pointing to the folder.
|
||||
By adding the student's primary email address to the CSV output, it can be used in subsequent commands.
|
||||
Sustitute for admin@domain.com and `<TeamDriveID>`.
|
||||
Sustitute for admin@domain.com and `<SharedDriveID>`.
|
||||
```
|
||||
Students.csv
|
||||
primaryEmail,Name
|
||||
@@ -299,7 +299,7 @@ mary@domain.com, Mary Smith
|
||||
...
|
||||
|
||||
# Create the student folders on the Shared Drive
|
||||
gam redirect csv ./StudentFolders.csv multiprocess csv Students.csv gam user admin@domain.com create drivefile mimetype gfolder drivefilename "~~Name~~ Digital Portfolio" parentid <TeamDriveID> csv addcsvdata primaryEmail "~primaryEmail"
|
||||
gam redirect csv ./StudentFolders.csv multiprocess csv Students.csv gam user admin@domain.com create drivefile mimetype gfolder drivefilename "~~Name~~ Digital Portfolio" parentid <SharedDriveID> csv addcsvdata primaryEmail "~primaryEmail"
|
||||
# Add ACLs granting the students write access to their folders; "~User" refers to admin@domain.com
|
||||
gam csv StudentFolders.csv gam user "~User" add drivefileacl "~id" user "~primaryEmail" role fileorganizer
|
||||
# Add a shortcut to the folder on the student's My Drive
|
||||
@@ -389,7 +389,7 @@ User: user@domain.com, Drive Folder Path:, Create
|
||||
|
||||
Build in a Shared Drive Folder
|
||||
```
|
||||
gam user user@domain.com create drivefolderpath path "Top Folder/Middle Folder/Bottom Folder/Sub Folder" teamdriveparent "TS Shared Drive" teamdriveparentname "TS SD6 Folder"
|
||||
gam user user@domain.com create drivefolderpath path "Top Folder/Middle Folder/Bottom Folder/Sub Folder" shareddriveparent "TS Shared Drive" shareddriveparentname "TS SD6 Folder"
|
||||
Getting all Drive Files/Folders that match query (mimeType = 'application/vnd.google-apps.folder' and name = 'TS SD6 Folder' and trashed = false) for user@domain.com
|
||||
Got 1 Drive File/Folder that matched query (mimeType = 'application/vnd.google-apps.folder' and name = 'TS SD6 Folder' and trashed = false) for user@domain.com...
|
||||
User: user@domain.com, Drive Folder Path:, Create
|
||||
@@ -495,10 +495,10 @@ You can change where the new file is to be located; this removes all other paren
|
||||
* `parentid <DriveFolderID>` - Folder ID.
|
||||
* `parentname <DriveFolderName>` - Folder name; the folder must be owned by `<UserTypeEntity>`.
|
||||
* `anyownerparentname <DriveFolderName>` - Folder name; the folder can be owned by any user, `<UserTypeEntity>` must be able to write to the folder.
|
||||
* `teamdriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specfic Shared Drive folder.
|
||||
* `teamdriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* `shareddriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specfic Shared Drive folder.
|
||||
* `shareddriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
|
||||
You can add/remove parent folders without affecting other parent folders.
|
||||
* `addparents|removeparents <DriveFolderIDList>` - Specify the parent folders by ID.
|
||||
|
||||
@@ -30,13 +30,13 @@
|
||||
(parentid <DriveFolderID>)|
|
||||
(parentname <DriveFolderName>)|
|
||||
(anyownerparentname <DriveFolderName>)|
|
||||
(teamdriveparentid <DriveFolderID>)|
|
||||
(teamdriveparent <SharedDriveName>)|
|
||||
(teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>)|
|
||||
(teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>))|
|
||||
(teamdriveparentid <DriveFolderID>)|(teamdriveparent <SharedDriveName>)|
|
||||
(teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>)|
|
||||
(teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>)
|
||||
(shareddriveparentid <DriveFolderID>)|
|
||||
(shareddriveparent <SharedDriveName>)|
|
||||
(shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>)|
|
||||
(shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>))|
|
||||
(shareddriveparentid <DriveFolderID>)|(shareddriveparent <SharedDriveName>)|
|
||||
(shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>)|
|
||||
(shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>)
|
||||
|
||||
<DriveOrderByFieldName> ::=
|
||||
createddate|createdtime|
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
- [Remove domainCanFind-domainWithLink ACLs for internal domain](#remove-domaincanfind-domainwithlink-acls-for-internal-domain)
|
||||
- [Remove My Drive ACLs for external domains](#remove-my-drive-acls-for-external-domains)
|
||||
- [Remove anyoneCanFind-anyoneWithLink ACLs](#remove-anyonecanfind-anyonewithlink-acls)
|
||||
- [Target Audiences](#target-audiences)
|
||||
|
||||
## API documentation
|
||||
* [Drive API - Permissions](https://developers.google.com/drive/api/v3/reference/permissions)
|
||||
@@ -143,6 +144,7 @@ specify `basicpermissions` and additional permission fields, e.g., `permissions.
|
||||
<FileSelector> | <CSVFileSelector> | <CSVkmdSelector> | <CSVDataSelector>
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Items
|
||||
```
|
||||
|
||||
## GUI API permission name mapping
|
||||
|
||||
| GUI setting | API setting |
|
||||
@@ -357,8 +359,8 @@ The `quotechar <Character>` option allows you to choose an alternate quote chara
|
||||
|
||||
For example, to get the ACLs for your Team Drives with the Team Drive name included in the output:
|
||||
```
|
||||
gam redirect csv ./TeamDrives.csv print teamdrives
|
||||
gam redirect csv ./TeamDriveACLs.csv multiprocess csv ./TeamDrives.csv gam print drivefileacls teamdriveid "~id" addtitle "~name" fields id,domain,emailaddress,role,type,deleted
|
||||
gam redirect csv ./SharedDrives.csv print shareddrives
|
||||
gam redirect csv ./SharedDriveACLs.csv multiprocess csv ./SharedDrives.csv gam print drivefileacls shareddriveid "~id" addtitle "~name" fields id,domain,emailaddress,role,type,deleted
|
||||
```
|
||||
|
||||
## Delete all ACLs except owner from a file
|
||||
@@ -616,3 +618,51 @@ Delete those Shared Drive ACLs.
|
||||
```
|
||||
gam config num_threads 20 redirect stdout ./DeleteSharedDriveShares.txt multiprocess redirect stderr stdout csv SharedDriveShares.csv gam user "~Owner" delete drivefileacl "~id" "id:~~permission.id~~"
|
||||
```
|
||||
|
||||
## Target Audiences
|
||||
|
||||
* See: https://support.google.com/a/answer/9934697
|
||||
|
||||
You can manage target audiences in the admin console at Directory/Target audiences.
|
||||
If you click on a target audience the URL will look like this: `https://admin.google.com/ac/targetaudiences/02xcytpi0xrdqxi`
|
||||
|
||||
You can add this target audience to a file with:
|
||||
```
|
||||
gam user user@domain.com create drivefileacl <DriveFileID> domain 02xcytpi0xrdqxi.audience.googledomains.com role reader
|
||||
User: user@domain.com, Add 1 Drive File/Folder ACL
|
||||
User: user@domain.com, Drive File/Folder ID: <DriveFileID>, Permission ID: 02xcytpi0xrdqxi.audience.googledomains.com, Added
|
||||
Test Audience
|
||||
id: 02897912034288871303
|
||||
type: domain
|
||||
domain: 02xcytpi0xrdqxi.audience.googledomains.com
|
||||
role: reader
|
||||
permissionDetails:
|
||||
role: reader
|
||||
type: file
|
||||
inherited: False
|
||||
allowFileDiscovery: False
|
||||
```
|
||||
|
||||
You can update the target audience role with:
|
||||
```
|
||||
gam user user@domain.com update drivefileacl <DriveFileID> id:02897912034288871303 role writer
|
||||
User: user@domain.com, Update 1 Drive File/Folder ACL
|
||||
User: user@domain.com, Drive File/Folder ID: <DriveFileID>, Permission ID: 02897912034288871303, Updated
|
||||
Test Audience
|
||||
id: 02897912034288871303
|
||||
type: domain
|
||||
domain: 02xcytpi0xrdqxi.audience.googledomains.com
|
||||
role: writer
|
||||
permissionDetails:
|
||||
role: writer
|
||||
type: file
|
||||
inherited: False
|
||||
allowFileDiscovery: False
|
||||
```
|
||||
|
||||
You can delete the target audience from a file with:
|
||||
```
|
||||
gam user user@domain.com delete drivefileacl <DriveFileID> id:02897912034288871303
|
||||
User: user@domain.com, Delete 1 Drive File/Folder ACL
|
||||
User: user@domain.com, Drive File/Folder ID: <DriveFileID>, Permission ID: 02897912034288871303, Deleted
|
||||
```
|
||||
|
||||
@@ -26,10 +26,10 @@
|
||||
(parentid <DriveFolderID>)|
|
||||
(parentname <DriveFolderName>)|
|
||||
(anyownerparentname <DriveFolderName>)|
|
||||
(teamdriveparentid <DriveFolderID>)|
|
||||
(teamdriveparent <SharedDriveName>)|
|
||||
(teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>)|
|
||||
(teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>)
|
||||
(shareddriveparentid <DriveFolderID>)|
|
||||
(shareddriveparent <SharedDriveName>)|
|
||||
(shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>)|
|
||||
(shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>)
|
||||
|
||||
```
|
||||
## Create shortcuts
|
||||
@@ -48,10 +48,10 @@ There are two modes of operaton:
|
||||
* `parentid <DriveFolderID>` - Folder ID.
|
||||
* `parentname <DriveFolderName>` - Folder name; the folder must be owned by `<UserTypeEntity>`.
|
||||
* `anyownerparentname <DriveFolderName>` - Folder name; the folder can be owned by any user, `<UserTypeEntity>` must be able to write to the folder.
|
||||
* `teamdriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specfic Shared Drive folder.
|
||||
* `teamdriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `teamdriveparentid <SharedDriveID> teamdriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `teamdriveparent <SharedDriveName> teamdriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* `shareddriveparentid <DriveFolderID>` - Shared Drive folder ID; when used alone, this indicates a specfic Shared Drive folder.
|
||||
* `shareddriveparent <SharedDriveName>` - Shared Drive name; when used alone, this indicates the root level of the Shared Drive.
|
||||
* `shareddriveparentid <SharedDriveID> shareddriveparentname <DriveFolderName>` - A Shared Drive ID and a folder name on that Shared Drive.
|
||||
* `shareddriveparent <SharedDriveName> shareddriveparentname <DriveFolderName>` - A Shared Drive name and a folder name on that Shared Drive.
|
||||
* `convertparents` - Convert all but the last parent reference in `<DriveFileEntity>` to shortcuts. My testing shows that as parents are added to a file, they are added to the front of the parents list; thus, the last parent is the original parent.
|
||||
|
||||
If neither `<DriveFileParentAttribute>` nor `convertparents` are specified, the shortcut is placed in the root folder (My Drive).
|
||||
@@ -142,6 +142,6 @@ gam csv Shortcuts.csv matchfield code 4 gam user "~owner" create drivefileshortc
|
||||
|
||||
## Check shortcut validity on Shared Drives
|
||||
```
|
||||
gam redirect csv ./TDShortcuts.csv user organizer@domain.com print filelist select teamdriveid <SharedDriveID> showmimetype gshortcut fields id
|
||||
gam redirect csv ./TDShortcuts.csv user organizer@domain.com print filelist select shareddriveid <SharedDriveID> showmimetype gshortcut fields id
|
||||
gam redirect csv ./Shortcuts.csv user organizer@domain.com check drivefileshortcut csvfile TDShortcuts.csv:id csv
|
||||
```
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
- [API documentation](#api-documentation)
|
||||
- [Definitions](#definitions)
|
||||
- [Aliases](#aliases)
|
||||
- [Delegation Notification](#delegation-notification)
|
||||
- [Delegator Banner](#delegator-banner)
|
||||
- [Delegate Notification](#delegate-notification)
|
||||
- [Create Gmail delegates](#create-gmail-delegates)
|
||||
- [Delete Gmail delegates](#delete-gmail-delegates)
|
||||
- [Update Gmail delegates](#update-gmail-delegates)
|
||||
@@ -57,7 +58,13 @@ The `convertalias` option causes GAM to make an extra API call per user in `<Use
|
||||
to convert aliases to primary email addresses. If you know that all of the email addresses
|
||||
in `<UserEntity>` are primary, you can omit `convertalias` and avoid the extra API calls.
|
||||
|
||||
## Delegation Notification
|
||||
## Delegator Banner
|
||||
When creating a delegate, the following banner is displayed in the delegator's Gmail inbox, it can not be suppressed.
|
||||
```
|
||||
<Delegate> now has delegated access to your account. This notice will end in 7 days.
|
||||
```
|
||||
|
||||
## Delegate Notification
|
||||
When creating a delegate, you can send a message to the delegate.
|
||||
```
|
||||
[notify [<Boolean>]
|
||||
|
||||
@@ -404,7 +404,7 @@ Messages are archived to the group specified by `<GroupItem>`.
|
||||
### Archive a selected set of messages
|
||||
* `((query <QueryGmail> [querytime<String> <Date>]*) (matchlabel <LabelName>) [or|and])+` - Criteria to select messages
|
||||
* `labelids <LabelIDList>` - Select messages with labels that match all of the specified label IDs.
|
||||
* `max_to_archive` - Limit the number of messages that will be archived; use a value of 0 for no limit
|
||||
* `max_to_archive <Number>` - Limit the number of messages that will be archived; use a value of 0 for no limit
|
||||
* `doit` - No messages are archived unless you specify `doit`. By not specifying `doit`, you can preview the messages selected to verify that the results match your expectations.
|
||||
|
||||
When `matchlabel <LabelName>` is specified, the following characters are replaced with a `-` in the generated query.
|
||||
@@ -412,8 +412,8 @@ When `matchlabel <LabelName>` is specified, the following characters are replace
|
||||
&()"|{}/
|
||||
```
|
||||
|
||||
By default, Gam fetches all matching messages from Google and then processes only `max_to_archive` of them.
|
||||
To speed up fetching, specify `quick` and only `max_to_archive` of the matching messages will be fetched.
|
||||
By default, Gam fetches all matching messages from Google and then archives only `max_to_archive <Number>` of them.
|
||||
To speed up fetching, specify `quick` and only `max_to_archive <Number>` of the matching messages will be fetched.
|
||||
You must still specify `doit` to perform the operation.
|
||||
|
||||
By default, the command results are displayed as indented keys and values. Use the `csv` option
|
||||
@@ -430,8 +430,6 @@ user@domain.com,18e9fc6581b9acab,Archived,
|
||||
user@domain.com,18e9fc58c5491f4c,Archived,
|
||||
```
|
||||
|
||||
See below for message selection.
|
||||
|
||||
## Export messages/threads
|
||||
Export messages in EML format.
|
||||
```
|
||||
@@ -447,6 +445,9 @@ gam <UserTypeEntity> export thread|threads
|
||||
[targetfolder <FilePath>] [targetname <FileName>] [overwrite [<Boolean>]]
|
||||
```
|
||||
|
||||
By default, Gam fetches all matching messages from Google and then exports only `max_to_export <Number>` of them.
|
||||
To speed up fetching, specify `quick` and only `max_to_export <Number>` of the matching messages will be fetched.
|
||||
|
||||
By default, when exporting a message, it is downloaded to the directory specified in `gam.cfg/drive_dir`.
|
||||
* `targetfolder <FilePath>` - Specify an alternate location for the downloaded file.
|
||||
|
||||
@@ -461,7 +462,18 @@ By default, when exporting a message, an existing local file will not be overwri
|
||||
* `overwrite true` - Overwite an existing file
|
||||
* `overwrite false` - Do not overwite an existing file; add a numeric prefix and create a new file
|
||||
|
||||
See below for message selection.
|
||||
### Export a specific set of messages
|
||||
* `ids <MessageIDEntity>` - A list of message ids
|
||||
|
||||
### Export a selected set of messages
|
||||
* `((query <QueryGmail> [querytime<String> <Date>]*) (matchlabel <LabelName>) [or|and])+` - Criteria to select messages
|
||||
* `labelids <LabelIDList>` - Select messages with labels that match all of the specified label IDs.
|
||||
* `max_to_export <Number>` - Limit the number of messages that will be exported; use a value of 0 for no limit
|
||||
|
||||
When `matchlabel <LabelName>` is specified, the following characters are replaced with a `-` in the generated query.
|
||||
```
|
||||
&()"|{}/
|
||||
```
|
||||
|
||||
## Forward messages/threads
|
||||
```
|
||||
@@ -477,6 +489,9 @@ gam <UserTypeEntity> forward thread|threads recipient|to <RecipientEntity>
|
||||
[subject <String>] [addorigfieldstosubject]
|
||||
```
|
||||
|
||||
By default, Gam fetches all matching messages from Google and then forwards only `max_to_forward <Number>` of them.
|
||||
To speed up fetching, specify `quick` and only `max_to_forwrd <Number>` of the matching messages will be fetched.
|
||||
|
||||
By default, the message subject has `Fwd: ` prepended; use `subject <String>` to specify a new subject.
|
||||
|
||||
All `Cc` addresses are removed from the forwarded message.
|
||||
@@ -486,7 +501,19 @@ If `addorigfieldstosubject` is specified, GAM appends the original `from`, `to`
|
||||
Fwd: Ross to TestUser (Original From: Ross Scroggs <ross.scroggs@gmail.com> To: testuser@domain.com Date: Thu, 23 Nov 2023 07:01:59 -0800)
|
||||
```
|
||||
|
||||
See below for message selection.
|
||||
### Forward a specific set of messages
|
||||
* `ids <MessageIDEntity>` - A list of message ids
|
||||
|
||||
### Forward a selected set of messages
|
||||
* `((query <QueryGmail> [querytime<String> <Date>]*) (matchlabel <LabelName>) [or|and])+` - Criteria to select messages
|
||||
* `labelids <LabelIDList>` - Select messages with labels that match all of the specified label IDs.
|
||||
* `max_to_forward <Number>` - Limit the number of messages that will be forwarded; use a value of 0 for no limit
|
||||
* `doit` - No messages are processed unless you specify `doit`. By not specifying `doit`, you can preview the messages selected to verify that the results match your expectations.
|
||||
|
||||
When `matchlabel <LabelName>` is specified, the following characters are replaced with a `-` in the generated query.
|
||||
```
|
||||
&()"|{}/
|
||||
```
|
||||
|
||||
## Manage messages/threads
|
||||
```
|
||||
@@ -538,7 +565,7 @@ user@domain.com,18e9fc58c5491f4c,Deleted,
|
||||
### Manage a selected set of messages
|
||||
* `((query <QueryGmail> [querytime<String> <Date>]*) (matchlabel <LabelName>) [or|and])+` - Criteria to select messages
|
||||
* `labelids <LabelIDList>` - Select messages with labels that match all of the specified label IDs.
|
||||
* `max_to_xxx` - Limit the number of messages that will be processed; use a value of 0 for no limit
|
||||
* `max_to_xxx <Number>` - Limit the number of messages that will be processed; use a value of 0 for no limit
|
||||
* `doit` - No messages are processed unless you specify `doit`. By not specifying `doit`, you can preview the messages selected to verify that the results match your expectations.
|
||||
|
||||
When `matchlabel <LabelName>` is specified, the following characters are replaced with a `-` in the generated query.
|
||||
@@ -546,8 +573,8 @@ When `matchlabel <LabelName>` is specified, the following characters are replace
|
||||
&()"|{}/
|
||||
```
|
||||
|
||||
By default, Gam fetches all matching messages from Google and then processes only `max_to_process` of them.
|
||||
To speed up fetching, specify `quick` and only `max_to_process` of the matching messages will be fetched.
|
||||
By default, Gam fetches all matching messages from Google and then processes only `max_to_process <Number>` of them.
|
||||
To speed up fetching, specify `quick` and only `max_to_process <Number>` of the matching messages will be fetched.
|
||||
You must still specify `doit` to perform the operation.
|
||||
|
||||
## Delete messages by Message-Id
|
||||
@@ -611,7 +638,7 @@ gam <UserTypeEntity> print messages|threads [todrive <ToDriveAttribute>*]
|
||||
```
|
||||
## Display all messages
|
||||
By default, Gam displays all messages.
|
||||
* `max_to_xxx` - Limit the number of messages that will be displayed
|
||||
* `max_to_print|max_to_show <Number>` - Limit the number of messages that will be displayed
|
||||
* `includespamtrash` - Include messages in the Spam and Trash folders
|
||||
|
||||
By default, all messages in a thread are displayed with `print|show threads`.
|
||||
@@ -627,7 +654,7 @@ gam user user@domain.com print|show threads maxmessagesperthread 1
|
||||
## Display a selected set of messages
|
||||
* `((query <QueryGmail> [querytime<String> <Date>]*) (matchlabel <LabelName>) [or|and])+` - Criteria to select messages
|
||||
* `labelids <LabelIDList>` - Select messages with labels that match all of the specified label IDs.
|
||||
* `max_to_xxx` - Limit the number of messages that will be displayed
|
||||
* `max_to_print|max_to_show <Number>` - Limit the number of messages that will be displayed
|
||||
* `includespamtrash` - Include messages in the Spam and Trash folders
|
||||
* `labelmatchpattern <REMatchPattern>` - Only display messages with some label that matches `<REMatchPattern>`
|
||||
* `labelmatchpattern xyz` - Label must start with xyz
|
||||
@@ -641,8 +668,8 @@ When `matchlabel <LabelName>` is specified, the following characters are replace
|
||||
&()"|{}/
|
||||
```
|
||||
|
||||
By default, Gam fetches only `max_to_process` matching messages from Google and then displays them.
|
||||
To see how many messages actually match, specify `notquick` and all matching messages will be fetched; only `max_to_process` of them will be displayed.
|
||||
By default, Gam fetches only `max_to_process <Number>` matching messages from Google and then displays them.
|
||||
To see how many messages actually match, specify `notquick` and all matching messages will be fetched; only `max_to_process <Number>` of them will be displayed.
|
||||
|
||||
### Difference between `From` and `Sender` headers
|
||||
The `From` header specifies the author of the message, that is,
|
||||
|
||||
@@ -116,7 +116,7 @@ gam <UserTypeEntity> show sendas [compact|format|html]
|
||||
```
|
||||
|
||||
These are the output formatting options:
|
||||
* `compact` - Escape carriage returns as \r and newlines as \n in original HTML; this format produces output that can be used as input to GAM
|
||||
* `compact` - Escape carriage returns as \r and newlines as \n in original HTML
|
||||
* `format` - Strip HTML keywords leaving basic printable information
|
||||
* `html` - Show original HTML; this is the default option; the output is human readable but cannot be used as input to GAM
|
||||
|
||||
@@ -184,12 +184,13 @@ If you have a current default signature, the API will update that, but if you de
|
||||
## Display signature
|
||||
### Display the signature as an indented list of keys and values.
|
||||
```
|
||||
gam <UserTypeEntity> show signature|sig [compact|format|html]
|
||||
gam <UserTypeEntity> show signature|sig [compact|format|html|template]
|
||||
[primary|default] [verifyonly]
|
||||
```
|
||||
|
||||
These are the output formatting options:
|
||||
* `compact` - Escape carriage returns as \r and newlines as \n in original HTML; this format produces output that can be used as input to GAM
|
||||
* `template` - Escape carriage returns as \r and newlines as \n in original HTML; this format produces output that can be used as input to GAM
|
||||
* `compact` - Escape carriage returns as \r and newlines as \n in original HTML
|
||||
* `format` - Strip HTML keywords leaving basic printable information
|
||||
* `html` - Show original HTML; this is the default option; the output is human readable but cannot be used an input to GAM
|
||||
|
||||
@@ -295,19 +296,10 @@ Use text like `{FirstName}` and `{Email}` in the locations where the actual valu
|
||||
|
||||
Once you're created the template signature, do the following:
|
||||
```
|
||||
$ gam user testuser@domain.com show signature compact > SimpleSig.html
|
||||
$ more SimpleSig.html
|
||||
SendAs Address: <testuser@domain.com>
|
||||
IsPrimary: True
|
||||
Default: True
|
||||
Signature: <div dir="ltr">--<div>Name: {FirstName} {LastName}<div>Phone: {Phone}</div><div>Email: {Email}</div></div><div><br></div><div>Company Name</div><div>Company Address</div><div><br></div></div>\n
|
||||
```
|
||||
Edit SimpleSig.html and delete all text from `SendAs ` through `Signature: `.
|
||||
The result should be:
|
||||
```
|
||||
$ gam redirect stdout ./SigTemplate.html user testuser@domain.com show signature template
|
||||
$ more SigTemplate.html
|
||||
<div dir="ltr">--<div>Name: {FirstName} {LastName}<div>Phone: {Phone}</div><div>Email: {Email}</div></div><div><br></div><div>Company Name</div><div>Company Address</div><div><br></div></div>\n
|
||||
```
|
||||
|
||||
This is a sample Users.csv file.
|
||||
```
|
||||
email,first,last,phone
|
||||
@@ -317,5 +309,20 @@ mjones@domain.com,Mary,Jones,510-555-1212 x 456
|
||||
|
||||
This command will update the user's signatures.
|
||||
```
|
||||
gam csv Users.csv gam user "~email" signature htmlfile SimpleSig.html replace FirstName "~first" replace LastName "~last" replace Phone "~phone" replace Email "~email"
|
||||
```
|
||||
gam csv Users.csv gam user "~email" signature htmlfile SigTemplate.html replace FirstName "~first" replace LastName "~last" replace Phone "~phone" replace Email "~email"
|
||||
```
|
||||
|
||||
You can also do the update with user attributes:
|
||||
|
||||
This is a sample Users.csv file.
|
||||
|
||||
```
|
||||
email
|
||||
bsmith@domain.com
|
||||
mjones@domain.com
|
||||
```
|
||||
|
||||
This command will update the user's signatures.
|
||||
```
|
||||
gam csv Users.csv gam user "~email" signature htmlfile SigTemplate.html replace FirstName field:name.givenname replace LastName field:name.familyname replace Phone field:phone.value.type.work replace Email field:email.primaryemail
|
||||
```
|
||||
|
||||
@@ -586,6 +586,9 @@ Getting all Groups for testuser1@domain.com (1/2)
|
||||
Getting all Groups for testuser2@domain.com (2/2)
|
||||
User,Groups,GroupsList
|
||||
testuser2@domain.com,0,
|
||||
|
||||
# Get group membership for all users
|
||||
$ gam config auto_batch_min 1 num_threads 10 redirect csv ./UsersGroups.csv multiprocess sortheaders User,Group redirect stderr - multiprocess all users print groups
|
||||
```
|
||||
### Display groups and their parents
|
||||
Display a user's groups and their parents as an indented list.
|
||||
|
||||
@@ -148,6 +148,8 @@
|
||||
<CSVkmdSelector> |
|
||||
<CSVDataSelector>
|
||||
|
||||
<QuerySharedDrive> ::= <String> See: https://developers.google.com/workspace/drive/api/guides/search-shareddrives
|
||||
|
||||
<SharedDriveACLRole> ::=
|
||||
manager|organizer|owner|
|
||||
contentmanager|fileorganizer|
|
||||
@@ -159,8 +161,8 @@
|
||||
<SharedDriveName> ::= <String>
|
||||
<SharedDriveEntity> ::=
|
||||
<SharedDriveID>|
|
||||
(teamdriveid <SharedDriveID>)|(teamdriveid:<SharedDriveID>)|
|
||||
(teamdrive <SharedDriveName>)|(teamdrive:<SharedDriveName>)
|
||||
(shareddriveid <SharedDriveID>)|(shareddriveid:<SharedDriveID>)|
|
||||
(shareddrive <SharedDriveName>)|(shareddrive:<SharedDriveName>)
|
||||
|
||||
<SharedDriveFieldName> ::=
|
||||
backgroundimagefile|
|
||||
@@ -174,10 +176,10 @@
|
||||
themeid
|
||||
<SharedDriveFieldNameList> ::= "<SharedDriveFieldName>(,<SharedDriveFieldName>)*"
|
||||
|
||||
<SharedDriveIDEntity> ::= (teamdriveid <DriveFileItem>) | (teamdriveid:<DriveFileItem>)
|
||||
<SharedDriveNameEntity> ::= (teamdrive <SharedDriveName>) | (teamdrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (teamdrivefilename <DriveFileName>) | (teamdrivefilename:<DriveFileName>)
|
||||
<SharedDriveFileQueryEntity> ::= (teamdrivequery <QueryDriveFile>) | (teamdrivequery:<QueryDriveFile>)
|
||||
<SharedDriveIDEntity> ::= (shareddriveid <DriveFileItem>) | (shareddriveid:<DriveFileItem>)
|
||||
<SharedDriveNameEntity> ::= (shareddrive <SharedDriveName>) | (shareddrive:<SharedDriveName>)
|
||||
<SharedDriveFileNameEntity> ::= (shareddrivefilename <DriveFileName>) | (shareddrivefilename:<DriveFileName>)
|
||||
<SharedDriveFileQueryEntity> ::= (shareddrivequery <QueryDriveFile>) | (shareddrivequery:<QueryDriveFile>)
|
||||
<SharedDriveFileQueryShortcut> ::=
|
||||
all_files | all_folders | all_google_files | all_non_google_files | all_items
|
||||
|
||||
@@ -291,11 +293,11 @@ When either of these options is chosen, no infomation about Shared Drive restric
|
||||
To retrieve the Shared Drive ID with `returnidonly`:
|
||||
```
|
||||
Linux/MacOS
|
||||
teamDriveId=$(gam user user@domain.com create shareddrive ... returnidonly)
|
||||
shareddriveId=$(gam user user@domain.com create shareddrive ... returnidonly)
|
||||
Windows PowerShell
|
||||
$teamDriveId = & gam user user@domain.com create shareddrive ... returnidonly
|
||||
$shareddriveId = & gam user user@domain.com create shareddrive ... returnidonly
|
||||
Windows Command Prompt
|
||||
for /f "delims=" %a in ('gam user user@domain.com create shareddrive ... returnidonly') do set teamDriveId=%a
|
||||
for /f "delims=" %a in ('gam user user@domain.com create shareddrive ... returnidonly') do set shareddriveId=%a
|
||||
```
|
||||
|
||||
## Bulk Create Shared Drives
|
||||
@@ -417,12 +419,12 @@ The `quotechar <Character>` option allows you to choose an alternate quote chara
|
||||
Display the number of Shared Drives.
|
||||
```
|
||||
gam <UserTypeEntity> show|print shareddrives
|
||||
[teamdriveadminquery|query <QueryTeamDrive>]
|
||||
[shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
showitemcountonly
|
||||
```
|
||||
By default, all Shared Drives are counted; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QuerySharedDrive>` - Use a query to select Shared Drives
|
||||
* `matchname <REMatchPattern>` - Retrieve Shared Drives with names that match a pattern.
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
|
||||
@@ -466,7 +468,7 @@ Options `shareddriveadminquery|query` and `shareddrives|teamdrives` are mutually
|
||||
Options `shareddriveadminquery|query` and `orgunit|org|ou` require `adminaccess|asadmin`.
|
||||
|
||||
By default, organizers for all Shared Drives are displayed; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddrives|teamdrives <SharedDriveIDList>` - Select the Shared Drive IDs specified in `<SharedDriveIDList>`
|
||||
* `shareddrives|teamdrives select <FileSelector>|<CSVFileSelector>` - Select the Shared Drive IDs specified in `<FileSelector>|<CSVFileSelector>`
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
@@ -486,7 +488,7 @@ To select organizers from any domain, use: `domainlist ""`
|
||||
|
||||
For example, to get a single user organizer from your domain for all Shared Drives including no organizer drives:
|
||||
```
|
||||
gam redirect csv ./TeamDriveOrganizers.csv print shareddriveorganizers
|
||||
gam redirect csv ./ShareddriveOrganizers.csv print shareddriveorganizers
|
||||
```
|
||||
|
||||
## Manage Shared Drive access
|
||||
@@ -596,14 +598,14 @@ The `quotechar <Character>` option allows you to choose an alternate quote chara
|
||||
## Display Shared Drive access for selected Shared Drives
|
||||
```
|
||||
gam <UserTypeEntity> show shareddriveacls
|
||||
adminaccess [teamdriveadminquery|query <QueryTeamDrive>]
|
||||
adminaccess [shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
[user|group <EmailAddress> [checkgroups]] (role|roles <SharedDriveACLRoleList>)*
|
||||
<PermissionMatch>* [<PermissionMatchAction>] [pmselect]
|
||||
[oneitemperrow] [<DrivePermissionsFieldName>*|(fields <DrivePermissionsFieldNameList>)]
|
||||
[formatjson [quotechar <Character>]]
|
||||
gam <UserTypeEntity> print shareddriveacls [todrive <ToDriveAttribute>*]
|
||||
adminaccess [teamdriveadminquery|query <QueryTeamDrive>]
|
||||
adminaccess [shareddriveadminquery|query <QuerySharedDrive>]
|
||||
[matchname <REMatchPattern>] [orgunit|org|ou <OrgUnitPath>]
|
||||
[user|group <EmailAddress> [checkgroups]] (role|roles <SharedDriveACLRoleList>)*
|
||||
<PermissionMatch>* [<PermissionMatchAction>] [pmselect]
|
||||
@@ -615,7 +617,7 @@ Shared Drives in the workspace, `<UserTypeEntity>` should specify a super admin
|
||||
option shoud be used.
|
||||
|
||||
By default, all Shared Drives are displayed; use the following options to select a subset of Shared Drives:
|
||||
* `teamdriveadminquery|query <QueryTeamDrive>` - Use a query to select Shared Drives
|
||||
* `shareddriveadminquery|query <QuerySharedDrive>` - Use a query to select Shared Drives
|
||||
* `matchname <REMatchPattern>` - Retrieve Shared Drives with names that match a pattern.
|
||||
* `orgunit|org|ou <OrgUnitPath>` - Only Shared Drives in the specified Org Unit are selected
|
||||
* `<PermissionMatch>* [<PermissionMatchAction>] pmselect` - Use permission matching to select Shared Drives
|
||||
|
||||
@@ -1018,6 +1018,10 @@ These existing options enable the display of additional information.
|
||||
* `(products|product <ProductIDList>)|(skus|sku <SKUIDList>)` - Display license information for a selected list of products/SKUs.
|
||||
* `schemas|custom|customschemas <SchemaNameList>` - Display all fields or selected fields of the specified custom schemas
|
||||
|
||||
You can use `license_skus = <SKUIDList>` in `gam.cfg` to list all of the licensing SKUs
|
||||
used in your workspace. Without this list or the `products|skus` options from above,
|
||||
GAM has to make 70+ API calls to get the licenses for a user; this can cause quota limit errors.
|
||||
|
||||
By default, Gam displays fields that only an adminstrator can view.
|
||||
* `userview` - Only display fields that other users in the domain can view.
|
||||
|
||||
@@ -1058,7 +1062,7 @@ gam print users [todrive <ToDriveAttribute>*]
|
||||
[delimiter <Character>] [sortheaders [<Boolean>]] [scalarsfirst [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]] [quoteplusphonenumbers]
|
||||
[issuspended <Boolean>] [isarchived <Boolean>] [aliasmatchpattern <REMatchPattern>]
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)*
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
```
|
||||
|
||||
By default, users in all domains in the account are selected; these options allow selection of subsets of users:
|
||||
@@ -1084,7 +1088,7 @@ gam print users [todrive <ToDriveAttribute>*] select <UserTypeEntity>
|
||||
[delimiter <Character>] [sortheaders [<Boolean>]] [scalarsfirst [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]] [quoteplusphonenumbers]
|
||||
[issuspended <Boolean>] [isarchived <Boolean>] [aliasmatchpattern <REMatchPattern>]
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)*
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
|
||||
gam <UserTypeEntity> print users [todrive <ToDriveAttribute>*]
|
||||
[orderby <UserOrderByFieldName> [ascending|descending]]
|
||||
@@ -1098,7 +1102,7 @@ gam <UserTypeEntity> print users [todrive <ToDriveAttribute>*]
|
||||
[delimiter <Character>] [sortheaders [<Boolean>]] [scalarsfirst [<Boolean>]]
|
||||
[formatjson [quotechar <Character>]] [quoteplusphonenumbers]
|
||||
[issuspended <Boolean>] [isarchived <Boolean>] [aliasmatchpattern <REMatchPattern>]
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)*
|
||||
[showvalidcolumn] (addcsvdata <FieldName> <String>)* [includecsvdatainjson [<Boolean>]]
|
||||
```
|
||||
|
||||
By default, Gam gets no group membership information for each user. The `groups` and `groupsincolumns`
|
||||
@@ -1167,6 +1171,9 @@ Add additional columns of data from the command line to the output
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format:
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
If `formatjson` and `addcsvdata` are specified, the option `includecsvdatainjson` causes GAM to add the
|
||||
additional field values to the JSON data.
|
||||
|
||||
When you perform `gam print users` with the following `todrive` options to update a sheet within a Google Sheets file:
|
||||
`tdfileid <DriveFileID> tdsheet <SheetEntity> tdupdatesheet`
|
||||
and your data includes international phone numbers that start with a plus sign, Google Sheets generates a `Formula parse error`
|
||||
|
||||
@@ -3,23 +3,23 @@
|
||||
Print the current version of Gam with details
|
||||
```
|
||||
gam version
|
||||
GAM 7.30.01 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM 7.34.05 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.14.1 64-bit final
|
||||
macOS Tahoe 26.1 x86_64
|
||||
Path: /Users/Admin/bin/gam7
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Time: 2023-06-02T21:10:00-07:00
|
||||
Python 3.14.3 64-bit final
|
||||
macOS Tahoe 26.3 arm64
|
||||
Path: /Users/gamteam/bin/gam7
|
||||
Config File: /Users/gamteam/GamConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Time: 2026-02-15T07:51:00-08:00
|
||||
```
|
||||
|
||||
Print the current version of Gam with details and time offset information
|
||||
```
|
||||
gam version timeoffset
|
||||
GAM 7.30.01 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM 7.34.05 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.14.1 64-bit final
|
||||
macOS Tahoe 26.1 x86_64
|
||||
Path: /Users/Admin/bin/gam7
|
||||
Python 3.14.3 64-bit final
|
||||
macOS Tahoe 26.3 arm64
|
||||
Path: /Users/gamteam/bin/gam7
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Your system time differs from www.googleapis.com by less than 1 second
|
||||
```
|
||||
@@ -27,29 +27,29 @@ Your system time differs from www.googleapis.com by less than 1 second
|
||||
Print the current version of Gam with extended details and SSL information
|
||||
```
|
||||
gam version extended
|
||||
GAM 7.30.01 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM 7.34.05 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.14.1 64-bit final
|
||||
macOS Tahoe 26.1 x86_64
|
||||
Path: /Users/Admin/bin/gam7
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Time: 2023-06-02T21:10:00-07:00
|
||||
Python 3.14.3 64-bit final
|
||||
macOS Tahoe 26.3 arm64
|
||||
Path: /Users/gamteam/bin/gam7
|
||||
Config File: /Users/gamteam/GamConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Time: 2026-02-15T07:51:00-08:00
|
||||
Your system time differs from admin.googleapis.com by less than 1 second
|
||||
OpenSSL 3.5.3 16 Sep 2025
|
||||
arrow 1.3.0
|
||||
OpenSSL 3.6.1 27 Jan 2026
|
||||
arrow 1.4.0
|
||||
chardet 5.2.0
|
||||
cryptography 46.0.1
|
||||
filelock 3.19.1
|
||||
google-api-python-client 2.182.0
|
||||
google-auth-httplib2 0.2.0
|
||||
google-auth-oauthlib 1.2.2
|
||||
google-auth 2.40.3
|
||||
lxml 6.0.1
|
||||
httplib2 0.31.0
|
||||
cryptography 46.0.5
|
||||
filelock 3.21.2
|
||||
google-api-python-client 2.190.0
|
||||
google-auth-httplib2 0.3.0
|
||||
google-auth-oauthlib 1.2.4
|
||||
google-auth 2.48.0
|
||||
lxml 6.0.2
|
||||
httplib2 0.31.2
|
||||
passlib 1.7.4
|
||||
pathvalidate 3.3.1
|
||||
pyscard 2.3.0
|
||||
yubikey-manager 5.8.0
|
||||
pyscard 2.3.1
|
||||
yubikey-manager 5.9.0
|
||||
admin.googleapis.com connects using TLSv1.3 TLS_AES_256_GCM_SHA384
|
||||
```
|
||||
|
||||
@@ -65,10 +65,10 @@ google-api-python-client 2.77.0
|
||||
httplib2 0.16.0
|
||||
oauth2client 4.1.3
|
||||
MacOS High Sierra 10.13.6 x86_64
|
||||
Path: /Users/Admin/bin/gam7
|
||||
Path: /Users/gamteam/bin/gam7
|
||||
Version Check:
|
||||
Current: 5.35.08
|
||||
Latest: 7.30.01
|
||||
Latest: 7.34.05
|
||||
echo $?
|
||||
1
|
||||
```
|
||||
@@ -76,7 +76,7 @@ echo $?
|
||||
Print the current version number without details
|
||||
```
|
||||
gam version simple
|
||||
7.30.01
|
||||
7.34.05
|
||||
```
|
||||
In Linux/MacOS you can do:
|
||||
```
|
||||
@@ -86,13 +86,13 @@ echo $VER
|
||||
Print the current version of Gam and address of this Wiki
|
||||
```
|
||||
gam help
|
||||
GAM 7.30.01 - https://github.com/GAM-team/GAM
|
||||
GAM 7.34.05 - https://github.com/GAM-team/GAM
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.14.1 64-bit final
|
||||
macOS Tahoe 26.1 x86_64
|
||||
Path: /Users/Admin/bin/gam7
|
||||
Config File: /Users/admin/GAMConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Time: 2023-06-02T21:10:00-07:00
|
||||
Help: Syntax in file /Users/Admin/bin/gam7/GamCommands.txt
|
||||
Python 3.14.3 64-bit final
|
||||
macOS Tahoe 26.3 arm64
|
||||
Path: /Users/gamteam/bin/gam7
|
||||
Config File: /Users/gamteam/GamConfig/gam.cfg, Section: DEFAULT, customer_id: my_customer, domain: domain.com
|
||||
Time: 2026-02-15T07:51:00-08:00
|
||||
Help: Syntax in file /Users/gamteam/bin/gam7/GamCommands.txt
|
||||
Help: Documentation is at https://github.com/GAM-team/GAM/wiki
|
||||
```
|
||||
|
||||
@@ -33,6 +33,7 @@ Notes and Information
|
||||
* [Questions? Visit the GAM Discussion Forum](https://groups.google.com/forum/#!forum/google-apps-manager)
|
||||
* [GAM Public Chat Room](GAM-Public-Chat-Room)
|
||||
* [Scripts](Scripts)
|
||||
* [Code Wiki](https://codewiki.google/github.com/gam-team/gam)
|
||||
* [Other Resources](Other-Resources)
|
||||
* [Drive REST API v3](Drive-REST-API-v3)
|
||||
* [BNF Syntax](BNF-Syntax)
|
||||
@@ -73,6 +74,7 @@ Client Access
|
||||
* [Calendars](Calendars)
|
||||
* [Calendars - Access](Calendars-Access)
|
||||
* [Calendars - Events](Calendars-Events)
|
||||
* [Calendars - Secondary Calendars with no Owner](No-Owner-Secondary-Calendars)
|
||||
* [Chrome Auto Update Expiration Counts](Chrome-AUE-Counts)
|
||||
* [Chrome Browser Cloud Management](Chrome-Browser-Cloud-Management)
|
||||
* [Chrome Device Counts](Chrome-Device-Counts)
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
ChromeOS-Devices.md Classroom-Courses.md Classroom-Membership.md Classroom-StudentGroups.md Cloud-Identity-Devices.md Cloud-Identity-Groups.md Domains.md GamUpdates.md Groups.md Mobile-Devices.md Organizational-Units.md Resources.md Shared-Drives.md Users-Shared-Drives.md Users.md
|
||||
163
wiki/gam.cfg.md
163
wiki/gam.cfg.md
@@ -1,6 +1,7 @@
|
||||
# GAM Configuration
|
||||
- [Introduction](#introduction)
|
||||
- [Variables](#variables)
|
||||
- [Set configuration variables](#set-configuration-variables)
|
||||
- [Multiple Computers](#multiple-computers)
|
||||
- [Separate Staff-Student Domains](#separate-staff-student-domains)
|
||||
- [Multiple Customers and Domains](#multiple-customers-and-domains)
|
||||
@@ -231,6 +232,11 @@ csv_output_header_order
|
||||
Any headers in the file but not in the list will appear after
|
||||
the headers in the list
|
||||
Default: ''
|
||||
csv_output_header_required
|
||||
A list of <Strings> used to specify column headers
|
||||
for inclusion in the CSV file written by a gam print command
|
||||
even if the API didn't return any data for those columns.
|
||||
Default: ''
|
||||
csv_output_line_terminator
|
||||
Allowed values: cr, lf, crlf
|
||||
Designates character(s) used to terminate the lines of a CSV file.
|
||||
@@ -276,7 +282,8 @@ csv_output_row_limit
|
||||
Default: 0
|
||||
csv_output_sort_headers
|
||||
A list of column headers that causes GAM to sort CSV output rows by those headers.
|
||||
The column headers are case insensitive and if column header does not appear in the CSV output, it is ignored.
|
||||
The column headers are case insensitive and if column header does not appear in the CSV output,
|
||||
it is ignored.
|
||||
Default: Blank
|
||||
csv_output_subfield_delimiter
|
||||
Character used to delimit fields and subfields in headers when writing CSV files;
|
||||
@@ -290,8 +297,6 @@ csv_output_timestamp_column
|
||||
csv_output_users_audit
|
||||
Gam print commands that print objects belonging to users
|
||||
don't print rows for users that don't have any of the objects.
|
||||
The objects are: calendars, calendar ACLs, calendar events, delegates, filters,
|
||||
forwarding addresses, sendas addresses, S/MIME certificates and tokens.
|
||||
When csv_output_users_audit is true, a placeholder row will be output with the
|
||||
user's email address; these rows will useful for auditing purposes only,
|
||||
they can not be successfuly used in a gam csv command.
|
||||
@@ -307,6 +312,21 @@ debug_level
|
||||
debug_redaction
|
||||
Enable/disable redaction of sensitive data from API debugging output
|
||||
Default: True
|
||||
developer_preview_apis
|
||||
A comma separated list of APIs requiring a Developer Preview key.
|
||||
Default: Blank
|
||||
Valid values:
|
||||
accesscontextmanager,admin,alertcenter,analyticsadmin,calendar-json,cbcm,chat,
|
||||
chromemanagement,chromepolicy,classroom,cloudchannel,cloudidentity,
|
||||
cloudresourcemanager,contactdelegation,contacts,datastudio,docs,drive,
|
||||
driveactivity,drivelabels,email-audit,forms,gmail,groupsmigration,groupssettings,
|
||||
iam,iamcredentials,keep,licensing,meet,mybusinessaccountmanagement,oauth2,
|
||||
orgpolicy,people,pubsub,reseller,searchconsole,serviceaccountlookup,
|
||||
servicemanagement,serviceusage,sheets,siteVerification,storage,tagmanager,tasks,
|
||||
vault,versionhistory,youtube
|
||||
developer_preview_api_key
|
||||
A Developer Preview API key that is passed to all API calls for APIs in developer_preview_apis
|
||||
Default: Blank
|
||||
device_max_results
|
||||
When retrieving lists of ChromeOS devices from API,
|
||||
how many should be retrieved in each API call
|
||||
@@ -325,13 +345,6 @@ drive_max_results
|
||||
how many should be retrieved in each API call
|
||||
Default: 1000
|
||||
Range: 1 - 1000
|
||||
drive_v3_beta
|
||||
Enable/disable use of Drive API v3 beta for Limited Folder Access testing
|
||||
Default: False
|
||||
drive_v3_native_names
|
||||
Enable/disable use of Drive API v3 native column names
|
||||
in all gam print/show commands related to Google Drive
|
||||
Default: True
|
||||
email_batch_size
|
||||
When archiving, printing, showing, trashing, untrashing, marking as spam Gmail messages.
|
||||
how many should be processed in each batch
|
||||
@@ -343,7 +356,8 @@ enable_dasa
|
||||
customer_id may not be set to my_customer
|
||||
Signal file: OldGamPath/enabledasa.txt
|
||||
enforce_expansive_access
|
||||
The default value for option `enforceexpansiveaccess` in all commands that delete or update drive file ACLs/permissions.
|
||||
The default value for option `enforceexpansiveaccess` in all commands that delete or update
|
||||
drive file ACLs/permissions.
|
||||
gam <UserTypeEntity> delete permissions
|
||||
gam <UserTypeEntity> delete drivefileacl
|
||||
gam <UserTypeEntity> update drivefileacl
|
||||
@@ -365,11 +379,12 @@ gmail_cse_incert_dir
|
||||
Directory for the S/MIME certificate files used by Gmail Client Side Encryption.
|
||||
Default: Blank
|
||||
gmail_cse_inkey_dir
|
||||
Directory for the Key Access Control List (KACL) wrapped private key data files used by Gmail Client Side Encryption.
|
||||
Directory for the Key Access Control List (KACL) wrapped private key data files used by
|
||||
Gmail Client Side Encryption.
|
||||
Default: Blank
|
||||
input_dir
|
||||
Input directory for files with non-absolute file names.
|
||||
The default
|
||||
The default is the current working directory.
|
||||
Default: .
|
||||
inter_batch_wait
|
||||
When processing items in batches, how many seconds should GAM wait between batches
|
||||
@@ -382,11 +397,9 @@ license_max_results
|
||||
Range: 10 - 1000
|
||||
license_skus
|
||||
A comma separated list of license SKUs; when getting licenses, only these SKUs will be processed.
|
||||
Each item in the list can be a <SKUID> which will be validated or <ProductID>/<SKUID> which will not
|
||||
Each item in the list can be a <SKUID> which will be validated or
|
||||
a <ProductID>/<SKUID> which will not be validated.
|
||||
Default: Blank
|
||||
meet_v2_beta
|
||||
Enable/disable use of Meet API v2 beta for additional Chat Space parameters.
|
||||
Default: False
|
||||
member_max_results
|
||||
When retrieving lists of Google Group members from API,
|
||||
how many should be retrieved in each API call
|
||||
@@ -401,7 +414,7 @@ member_max_results_ci_basic
|
||||
member_max_results_ci_full
|
||||
When retrieving lists of Cloud Identity Group members from API
|
||||
with either the basic or full options,
|
||||
how many should be retrieved in each API call
|
||||
how many should be retrieved in each API call
|
||||
Default: 500
|
||||
Range: 1 - 500
|
||||
message_batch_size
|
||||
@@ -460,6 +473,10 @@ oauth2_txt
|
||||
Path to oauth2.txt
|
||||
Default: GamConfigDir/oauth2.txt
|
||||
Environment variable: OAUTHFILE
|
||||
oauth2_txt_lock_mode
|
||||
Allowed values: 644, 664, 666
|
||||
File permissions for oauth2.txt.lock
|
||||
Default: 644
|
||||
oauth2service_json
|
||||
Path to oauth2service.json
|
||||
Default: GamConfigDir/oauth2service.json
|
||||
@@ -500,8 +517,9 @@ print_cros_ous_and_children
|
||||
This allows predefining the list of org units so they don't have to be specified in each command.
|
||||
Default: Blank
|
||||
process_wait_limit
|
||||
When processing batch/CSV files, how long (in seconds) GAM should wait for all batch|csv processes to complete
|
||||
after all have been started. If the limit is reached, GAM terminates any remaining processes.
|
||||
When processing batch/CSV files, how long (in seconds) GAM should wait for all
|
||||
batch|csv processes to complete after all have been started.
|
||||
If the limit is reached, GAM terminates any remaining processes.
|
||||
Default: 0: no limit
|
||||
Range: 0 - Unlimited
|
||||
quick_cros_move
|
||||
@@ -569,7 +587,7 @@ timezone
|
||||
to your local timezone. If you are running GAM on a remote computer or on a
|
||||
cloud shell, "local" will mean the time at the remote/cloud shell computer,
|
||||
not your location, Use "+|-hh:mm" to specify the timezone at your location.
|
||||
Starting with version 7.21.00 you can use a timezone name; the names are case sensitive.
|
||||
Starting with version 7.21.00 you can use a timezone name; the names are case sensitive.
|
||||
See: https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
|
||||
Default: utc
|
||||
Range: utc|z|local|(+|-hh:mm)|<ValidTimezoneName>
|
||||
@@ -582,10 +600,12 @@ tls_min_version
|
||||
The minimum TLS version to use in https connections
|
||||
Default: ''
|
||||
todrive_clearfilter
|
||||
Enable/disable clearing the spreadsheet basic filter when uploading data to an existing sheet in an existing file.
|
||||
Enable/disable clearing the spreadsheet basic filter when uploading data to an existing sheet in
|
||||
an existing file.
|
||||
Default: False
|
||||
todrive_clientaccess
|
||||
Enable/disable use of client access rather than service account access when uploading files with todrive
|
||||
Enable/disable use of client access rather than service account access when uploading files
|
||||
with todrive
|
||||
Default: False
|
||||
todrive_conversion
|
||||
Enable/disable conversion of CSV files to Google Sheets when todrive is specified
|
||||
@@ -636,8 +656,9 @@ todrive_user
|
||||
Email address of user to receive CSV files when todrive is specified
|
||||
Default: '' which becomes admin user in admin_email or address from oauth2.txt
|
||||
truncate_client_id
|
||||
Prior to version 6.74.00, GAM stripped '.apps.googleusercontent.com' from the client_id in oauth2.txt
|
||||
and passed the truncated value in API calls; this is no longer performed unless truncate_client_id is true
|
||||
Prior to version 6.74.00, GAM stripped '.apps.googleusercontent.com' from the client_id
|
||||
in oauth2.txt and passed the truncated value in API calls; this is no longer performed
|
||||
unless truncate_client_id is true
|
||||
Default: False
|
||||
update_cros_ou_with_id
|
||||
Update the OU of a Chromebook with the OU ID rather than the OU path.
|
||||
@@ -675,7 +696,7 @@ user_service_account_access_only
|
||||
```
|
||||
This is sample output:
|
||||
```
|
||||
$gam select default verify.
|
||||
$gam select default verify
|
||||
Config File: /Users/admin/.gam/gam.cfg, Initialized
|
||||
Section: DEFAULT
|
||||
activity_max_results = 100
|
||||
@@ -714,6 +735,8 @@ Section: DEFAULT
|
||||
csv_output_header_drop_filter = ''
|
||||
csv_output_header_filter = ''
|
||||
csv_output_header_force = ''
|
||||
csv_output_header_order = ''
|
||||
csv_output_header_required = ''
|
||||
csv_output_line_terminator = lf
|
||||
csv_output_no_escape_char = false
|
||||
csv_output_quote_char = '"'
|
||||
@@ -802,6 +825,33 @@ Section: DEFAULT
|
||||
user_service_account_access_only = false
|
||||
```
|
||||
|
||||
## Set configuration variables
|
||||
You can set variables in gam.cfg with an editor or from the command line with GAM.
|
||||
|
||||
```
|
||||
<Config> ::=
|
||||
config (<VariableName> [=] <Value>)* [save] [verify [variables <RESearchPattern>]]
|
||||
```
|
||||
- `<VariableName> [=] <Value>`
|
||||
- Set `<VariableName> = <Value>` in the current section
|
||||
- All `<VariableNames>` except section are allowed.
|
||||
- The `=` is optional but must be surrounded by spaces if included.
|
||||
- `save`
|
||||
- Write configuration data to gam.cfg
|
||||
- `verify`
|
||||
- Print the variable values for the current section
|
||||
- Use `variables <RESearchPattern>` to display variables with names selected by `<RESearchPattern>`
|
||||
- Values are determined in this order: Current section, DEFAULT section, Program default
|
||||
|
||||
You can prefix `<Config>` with `<Select>` to set a variable in a particular section.
|
||||
* `select default <Config>` - Set a variable in the `DEFAULT` section
|
||||
* `select xyz <Config>` - Set a variable in the `xyz` section
|
||||
|
||||
For example, to set yiur workspace Customer ID and domain name:
|
||||
```
|
||||
gam config customer_id C0123abc domain mydomain.org save
|
||||
```
|
||||
|
||||
## Multiple Computers
|
||||
You can install GAM on multiple computers, all using the same project. After installing GAM on your
|
||||
initial computer, follow these quidelines.
|
||||
@@ -849,7 +899,7 @@ it's how you quickly switch from from one client to another.
|
||||
|
||||
The arguments are optional, must appear in this order and must be the first arguments before any other GAM arguments.
|
||||
```
|
||||
select <Section> [save] [verify]
|
||||
select <Section> [save] [verify [variables <RESearchPattern>]]
|
||||
Use <Section> from gam.cfg for the current GAM command.
|
||||
<Section> is case-sensitive except for DEFAULT which is case-insensitive.
|
||||
save
|
||||
@@ -857,6 +907,7 @@ select <Section> [save] [verify]
|
||||
Write configuration data to gam.cfg
|
||||
verify
|
||||
Print the variable values for the current section
|
||||
Use `variables <RESearchPattern>` to display variables with names selected by `<RESearchPattern>`
|
||||
Values are determined in this order: Current section, DEFAULT section, Program default
|
||||
```
|
||||
Display all of the sections in gam.cfg and mark the currently selected section with a *.
|
||||
@@ -865,7 +916,7 @@ showsections
|
||||
```
|
||||
The config argument is used to set selected variables in gam.cfg via the command line.
|
||||
```
|
||||
config [<VariableName> [=] <Value>]* [save] [verify]
|
||||
config [<VariableName> [=] <Value>]* [save] [verify [variables <RESearchPattern>]]
|
||||
<VariableName> [=] <Value>
|
||||
Set <VariableName> = <Value> in the current section
|
||||
All <VariableNames> except section are allowed.
|
||||
@@ -874,6 +925,7 @@ config [<VariableName> [=] <Value>]* [save] [verify]
|
||||
Write configuration data to gam.cfg
|
||||
verify
|
||||
Print the variable values for the current section
|
||||
Use `variables <RESearchPattern>` to display variables with names selected by `<RESearchPattern>`
|
||||
Values are determined in this order: Current section, DEFAULT section, Program default
|
||||
|
||||
redirect csv <FileName> [multiprocess] [append] [noheader] [charset <Charset>] [columndelimiter <Character>]
|
||||
@@ -897,7 +949,7 @@ Edit gam.cfg to set up additional clients; it should look like this when complet
|
||||
activity_max_results = 100
|
||||
admin_email = ''
|
||||
api_calls_rate_check = false
|
||||
api_calls_rate_limit = 1000
|
||||
api_calls_rate_limit = 100
|
||||
api_calls_tries_limit = 10
|
||||
auto_batch_min = 0
|
||||
bail_on_internal_error_tries = 2
|
||||
@@ -907,55 +959,75 @@ cache_dir = /Users/admin/.gam/gamcache
|
||||
cache_discovery_only = true
|
||||
channel_customer_id = ''
|
||||
charset = utf-8
|
||||
cmdlog = ''
|
||||
cmdlog_max_backups = 5
|
||||
cmdlog_max_kilo_bytes = 1000
|
||||
chat_max_results = 100
|
||||
classroom_max_results = 0
|
||||
client_secrets_json = client_secrets.json
|
||||
clock_skew_in_seconds = 10
|
||||
cmdlog = ''
|
||||
cmdlog_max_backups = 5
|
||||
cmdlog_max_kilo_bytes = 1000
|
||||
config_dir = /Users/admin/.gam
|
||||
contact_max_results = 100
|
||||
csv_input_column_delimiter = ,
|
||||
csv_input_no_escape_char = true
|
||||
csv_input_quote_char = '"'
|
||||
csv_input_row_drop_filter = ''
|
||||
csv_input_row_drop_filter_mode = anymatch
|
||||
csv_input_row_filter = ''
|
||||
csv_input_row_filter_mode = allmatch
|
||||
csv_input_row_limit = 0
|
||||
csv_output_column_delimiter = ,
|
||||
csv_output_convert_cr_nl = false
|
||||
csv_output_field_delimiter = ' '
|
||||
csv_output_header_drop_filter = ''
|
||||
csv_output_header_filter = ''
|
||||
csv_output_header_force = ''
|
||||
csv_output_header_order = ''
|
||||
csv_output_header_required = ''
|
||||
csv_output_line_terminator = lf
|
||||
csv_output_no_escape_char = false
|
||||
csv_output_quote_char = '"'
|
||||
csv_output_row_drop_filter =
|
||||
csv_output_row_drop_filter = ''
|
||||
csv_output_row_drop_filter_mode = anymatch
|
||||
csv_output_row_filter = ''
|
||||
csv_output_row_filter_mode = allmatch
|
||||
csv_output_row_limit = 0
|
||||
csv_output_sort_headers = ''
|
||||
csv_output_subfield_delimiter = '.'
|
||||
csv_output_timestamp_column = ''
|
||||
csv_output_users_audit = false
|
||||
customer_id = my_customer
|
||||
debug_level = 0
|
||||
debug_redaction = true
|
||||
developer_preview_api_key = ''
|
||||
developer_preview_apis = ''
|
||||
device_max_results = 200
|
||||
domain =
|
||||
domain = ''
|
||||
drive_dir = /Users/admin/Downloads
|
||||
drive_max_results = 1000
|
||||
drive_v3_native_names = true
|
||||
email_batch_size = 100
|
||||
email_batch_size = 50
|
||||
enable_dasa = false
|
||||
enable_gcloud_reauth = false
|
||||
enforce_expansive_access = true
|
||||
event_max_results = 250
|
||||
extra_args =
|
||||
extra_args = ''
|
||||
gmail_cse_incert_dir = ''
|
||||
gmail_cse_inkey_dir = ''
|
||||
input_dir = .
|
||||
inter_batch_wait = 0
|
||||
license_max_results = 100
|
||||
license_sku = ''
|
||||
license_skus = ''
|
||||
member_max_results = 200
|
||||
member_max_results_ci_basic = 1000
|
||||
member_max_results_ci_full = 500
|
||||
message_batch_size = 50
|
||||
message_max_results = 1000
|
||||
message_max_results = 500
|
||||
mobile_max_results = 100
|
||||
multiprocess_pool_limit = 0
|
||||
never_time = Never
|
||||
no_browser = false
|
||||
no_cache = false
|
||||
no_short_urls = true
|
||||
no_update_check = true
|
||||
no_verify_ssl = false
|
||||
num_tbatch_threads = 2
|
||||
@@ -969,9 +1041,10 @@ print_agu_domains = ''
|
||||
print_cros_ous = ''
|
||||
print_cros_ous_and_children = ''
|
||||
process_wait_limit = 0
|
||||
quick_cros_move = False
|
||||
quick_info_user = False
|
||||
quick_cros_move = false
|
||||
quick_info_user = false
|
||||
reseller_id = ''
|
||||
retry_api_service_not_available = false
|
||||
section =
|
||||
show_api_calls_retry_data = false
|
||||
show_commands = false
|
||||
@@ -986,26 +1059,28 @@ smtp_password = ''
|
||||
smtp_username = ''
|
||||
timezone = utc
|
||||
tls_max_version = ''
|
||||
tls_min_version = 'TLSv1_2'
|
||||
tls_min_version = 'TLSv1_3'
|
||||
todrive_clearfilter = false
|
||||
todrive_clientaccess = false
|
||||
todrive_conversion = true
|
||||
todrive_localcopy = false
|
||||
todrive_locale = ''
|
||||
todrive_no_escape_char = true
|
||||
todrive_nobrowser = false
|
||||
todrive_noemail = true
|
||||
todrive_no_escape_char = true
|
||||
todrive_parent = root
|
||||
todrive_sheet_timeformat = ''
|
||||
todrive_sheet_timestamp = false
|
||||
todrive_timeformat = ''
|
||||
todrive_timestamp = false
|
||||
todrive_timezone = ''
|
||||
todrive_upload_nodata = true
|
||||
todrive_user = ''
|
||||
truncate_client_id = false
|
||||
update_cros_ou_with_id = false
|
||||
use_chat_admin_access = false
|
||||
use_course_owner_access = false
|
||||
use_projectid_as_name = false
|
||||
|
||||
user_max_results = 500
|
||||
user_service_account_access_only = false
|
||||
|
||||
|
||||
Reference in New Issue
Block a user