mirror of
https://github.com/GAM-team/GAM.git
synced 2026-06-21 06:31:37 +00:00
Compare commits
2 Commits
v7.00.35
...
20241105.2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f24629602c | ||
|
|
e5125b6853 |
@@ -66,9 +66,12 @@ Client access works when accessing Resource calendars.
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Items
|
||||
<DomainName> ::= <String>(.<String>)+
|
||||
<EmailAddress> ::= <String>@<DomainName>
|
||||
<EmailAddressList> ::= "<EmailAddess>(,<EmailAddress>)*"
|
||||
<EmailAddressEntity> ::= <EmailAddressList> | <FileSelector> | <CSVFileSelector> | <CSVkmdSelector> | <CSVDataSelector>
|
||||
<EmailAddressList> ::= "<EmailAddress>(,<EmailAddress>)*"
|
||||
<EmailAddressEntity> ::=
|
||||
<EmailAddressList> | <FileSelector> | <CSVFileSelector> |
|
||||
<CSVkmdSelector> | <CSVDataSelector>
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Items
|
||||
<iCalUID> ::= <String>
|
||||
|
||||
<EventAttachmentsSubfieldName> ::=
|
||||
attachments.fileid|
|
||||
|
||||
@@ -10,6 +10,10 @@ 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.00.36
|
||||
|
||||
Updated `gam print chromeapps` to correct a trap caused by an API change.
|
||||
|
||||
### 7.00.35
|
||||
|
||||
Classification labels are now available for Gmail in addition to Drive.
|
||||
|
||||
@@ -251,7 +251,7 @@ 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.00.35 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM 7.00.36 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.13.0 64-bit final
|
||||
MacOS Sonoma 14.5 x86_64
|
||||
@@ -923,7 +923,7 @@ 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
|
||||
GAM7 7.00.35 - https://github.com/GAM-team/GAM - pythonsource
|
||||
GAM7 7.00.36 - https://github.com/GAM-team/GAM - pythonsource
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.13.0 64-bit final
|
||||
Windows-10-10.0.17134 AMD64
|
||||
|
||||
@@ -91,20 +91,23 @@
|
||||
|
||||
<JSONData> ::= (json [charset <Charset>] <String>) | (json file <FileName> [charset <Charset>]) |
|
||||
|
||||
<CalendarItem> ::= <EmailAddress>
|
||||
<CalendarList> ::= "<CalendarItem>(,<CalendarItem>)*"
|
||||
<CalendarEntity> ::= <CalendarList> | <FileSelector> | <CSVkmdSelector> | <CSVDataSelector>
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Items
|
||||
<DomainName> ::= <String>(.<String>)+
|
||||
<EmailAddress> ::= <String>@<DomainName>
|
||||
<EmailAddressList> ::= "<EmailAddress>(,<EmailAddress>)*"
|
||||
<EmailAddressEntity> ::=
|
||||
<EmailAddressList> | <FileSelector> | <CSVFileSelector> |
|
||||
<EmailAddressList> | <FileSelector> | <CSVFileSelector> |
|
||||
<CSVkmdSelector> | <CSVDataSelector>
|
||||
See: https://github.com/GAM-team/GAM/wiki/Collections-of-Users
|
||||
<CalendarItem> ::= <EmailAddress>
|
||||
<CalendarList> ::= "<CalendarItem>(,<CalendarItem>)*"
|
||||
<CourseAlias> ::= <String>
|
||||
<CourseID> ::= <Number>|d:<CourseAlias>
|
||||
<CourseIDList> ::= "<CourseID>(,<CourseID>)*"
|
||||
<CourseState> ::= active|archived|provisioned|declined
|
||||
<CourseStateList> ::= all|"<CourseState>(,<CourseState>)*"
|
||||
<iCalUID> ::= <String>
|
||||
<ResourceID> ::= <String>
|
||||
<ResourceIDList> ::= "<ResourceID>(,<ResourceID>)*"
|
||||
<UniqueID> ::= id:<String>
|
||||
@@ -122,7 +125,7 @@
|
||||
allcalendars|
|
||||
primary|
|
||||
<EmailAddress>|
|
||||
<UniqueUD>|
|
||||
<UniqueID>|
|
||||
(courses <CourseIDList>)|
|
||||
((courses_with_teacher <UserItem>)|my_courses_as_teacher
|
||||
[coursestates <CourseStateList>])|
|
||||
|
||||
@@ -4,10 +4,10 @@
|
||||
- [Notes](#notes)
|
||||
- [Definitions](#definitions)
|
||||
- [Introduction](#introduction)
|
||||
- [Display Drive Labels](#display-drive-labels)
|
||||
- [Process File Drive Labels](#process-file-drive-labels)
|
||||
- [Manage Drive Label Permissions](#manage-drive-label-permissions)
|
||||
- [Display Drive Label Permissions](#display-drive-label-permissions)
|
||||
- [Display Classification Labels](#display-classification-labels)
|
||||
- [Manage Classification Label Permissions](#manage-classification-label-permissions)
|
||||
- [Display Classification Label Permissions](#display-classification-label-permissions)
|
||||
- [Process Drive File Classification Labels](#process-drive-file-classification-labels)
|
||||
|
||||
## API documentation
|
||||
* https://support.google.com/a/answer/9292382
|
||||
@@ -24,31 +24,39 @@ To use these commands you must add the 'Drive Labels API' to your project and up
|
||||
gam update project
|
||||
gam user user@domain.com update serviceaccount
|
||||
```
|
||||
Supported editions for this feature: Business Standard and Business Plus; Enterprise; Education Standard and Education Plus; G Suite Business; Essentials.
|
||||
Supported editions for this feature:
|
||||
```
|
||||
Frontline Starter and Frontline Standard
|
||||
Business Standard and Business Plus
|
||||
Enterprise Standard and Enterprise Plus
|
||||
Education Standard and Education Plus
|
||||
Essentials, Enterprise Essentials, and Enterprise Essentials Plus
|
||||
G Suite Business
|
||||
```
|
||||
|
||||
## Definitions
|
||||
* [`<DriveFileEntity>`](Drive-File-Selection)
|
||||
* [`<UserTypeEntity>`](Collections-of-Users)
|
||||
* [`<DriveLabelNameEntity>`, `<DriveLabelPermissionNameEntity'](Collections-of-Items)
|
||||
* [`<ClassificationLabelNameEntity>`, `<ClassificationLabelPermissionNameEntity`](Collections-of-Items)
|
||||
* [`<UserTypeEntity>`](Collections-of-Items)
|
||||
|
||||
```
|
||||
<DriveLabelID> ::= <String>
|
||||
<DriveLabelIDList> ::= "<DriveLabelID>(,<DriveLabelID)*"
|
||||
<ClassificationLabelID> ::= <String>
|
||||
<ClassificationLabelIDList> ::= "<ClassificationLabelID>(,<ClassificationLabelID)*"
|
||||
|
||||
<DriveLabelName> ::= labels/<DriveLabelID>[@latest|@published|@<Number>]
|
||||
<DriveLabelNameList> ::= "<DriveLabelName>(,<DriveLabelName)*"
|
||||
<DriveLabelNameEntity> ::=
|
||||
<DriveLabelNameList> | <FileSelector> | <CSVFileSelector> | <CSVDataSelector>
|
||||
<ClassificationLabelName> ::= labels/<ClassificationLabelID>[@latest|@published|@<Number>]
|
||||
<ClassificationLabelNameList> ::= "<ClassificationLabelName>(,<ClassificationLabelName)*"
|
||||
<ClassificationLabelNameEntity> ::=
|
||||
<ClassificationLabelNameList> | <FileSelector> | <CSVFileSelector> | <CSVDataSelector>
|
||||
|
||||
<DriveLabelPermissionName> ::= labels/<DriveLabelID>[@latest|@published|@<Number>]/permissions/(audiences|groups|people)/<String>
|
||||
<DriveLabelPermissionNameList> ::= "<DriveLabelPermissionName>(,<DriveLabelPermissionName>)*"
|
||||
<DriveLabelPermissionNameEntity> ::=
|
||||
<DriveLabelPermissionNameList> | <FileSelector> | <CSVFileSelector> | <CSVDataSelector>
|
||||
<ClassificationLabelPermissionName> ::= labels/<ClassificationLabelID>[@latest|@published|@<Number>]/permissions/(audiences|groups|people)/<String>
|
||||
<ClassificationLabelPermissionNameList> ::= "<ClassificationLabelPermissionName>(,<ClassificationLabelPermissionName>)*"
|
||||
<ClassificationLabelPermissionNameEntity> ::=
|
||||
<ClassificationLabelPermissionNameList> | <FileSelector> | <CSVFileSelector> | <CSVDataSelector>
|
||||
|
||||
<DriveLabelFieldID> ::= <String>
|
||||
<DriveLabelSelectionID> ::= <String>
|
||||
<DriveLabelSelectionIDList> ::= "<DriveLabelSelectionID>(,<DriveLabelSelectionID)*"
|
||||
<ClassificationLabelFieldID> ::= <String>
|
||||
<ClassificationLabelSelectionID> ::= <String>
|
||||
<ClassificationLabelSelectionIDList> ::= "<ClassificationLabelSelectionID>(,<ClassificationLabelSelectionID)*"
|
||||
|
||||
<BCP47LanguageCode> ::=
|
||||
ar-sa| # Arabic Saudi Arabia
|
||||
@@ -99,10 +107,10 @@ Three forms of the commands are available:
|
||||
* `gam <UserTypeEntity> action ... adminaccess` - The user named in `<UserTypeEntty>` is used, adminaccess indicates that labels of type `SHARED` and `ADMIN`can be processed
|
||||
* `gam <UserTypeEntity> action ...` - The user named in `<UserTypeEntty>` is used, access is limited, onlylabels of type `SHARED` can be processed
|
||||
|
||||
## Display Drive Labels
|
||||
## Display Classification Labels
|
||||
|
||||
```
|
||||
gam [<UserTypeEntity>] info drivelabels <DriveLabelNameEntity>
|
||||
gam [<UserTypeEntity>] info classificationlabels <ClassificationLabelNameEntity>
|
||||
[[basic|full] [languagecode <BCP47LanguageCode>]
|
||||
[formatjson] [adminaccess|asadmin]
|
||||
```
|
||||
@@ -115,7 +123,7 @@ By default, Gam displays the information as an indented list of keys and values.
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
```
|
||||
gam [<UserTypeEntity>] show drivelabels
|
||||
gam [<UserTypeEntity>] show classificationlabels
|
||||
[basic|full] [languagecode <BCP47LanguageCode>]
|
||||
[publishedonly [<Boolean>]] [minimumrole applier|editor|organizer|reader]
|
||||
[formatjson] [adminaccess|asadmin]
|
||||
@@ -130,7 +138,7 @@ By default, Gam displays the information as an indented list of keys and values.
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
```
|
||||
gam [<UserTypeEntity>] print drivelabels [todrive <ToDriveAttribute>*]
|
||||
gam [<UserTypeEntity>] print classificationlabels [todrive <ToDriveAttribute>*]
|
||||
[basic|full] [languagecode <BCP47LanguageCode>]
|
||||
[publishedonly [<Boolean>]] [minimumrole applier|editor|organizer|reader]
|
||||
[formatjson [quotechar <Character>]] [adminaccess|asadmin]
|
||||
@@ -150,25 +158,10 @@ 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.
|
||||
|
||||
## Process File Drive Labels
|
||||
`<DriveLabelID>`, `<DriveLabelFieldID>` and `<DriveLabelSelectionID>` values are obtained from the commands above.
|
||||
## Manage Classification Label Permissions
|
||||
Create a permission for a Classification Label by specifying the label name and the principal.
|
||||
```
|
||||
gam <UserTypeEntity> process filedrivelabels <DriveFileEntity>
|
||||
(addlabel <DriveLabelIDList>)*
|
||||
(deletelabel <DriveLabelIDList>)*
|
||||
(addlabelfield <DriveLabelID> <DriveLabelFieldID>
|
||||
(text <String>)|selection <DriveLabelSelectionIDList>)|
|
||||
(integer <Number>)|(date <Date>)|(user <EmailAddressList>))*
|
||||
(deletelabelfield <DriveLabelID> <DriveLabelFieldID>)*
|
||||
[nodetails]
|
||||
```
|
||||
|
||||
By default, details of the process labels are displayed, use `nodetails` to suppress this display.
|
||||
|
||||
## Manage Drive Label Permissions
|
||||
Create a permission for a Drive Label by specifying the label name and the principal.
|
||||
```
|
||||
gam [<UserTypeEntity>] create drivelabelpermission <DriveLabelNameEntity>
|
||||
gam [<UserTypeEntity>] create classificationlabelpermission <ClassificationLabelNameEntity>
|
||||
(user <UserItem>) | (group <GroupItem) | (audience <String>)
|
||||
role applier|editor|organizer|reader
|
||||
[nodetails|formatjson] [adminaccess|asadmin]
|
||||
@@ -178,22 +171,22 @@ By default, when a permission is created, GAM outputs details of the permission
|
||||
* `nodetails` - Suppress the details output.
|
||||
* `formatjson` - Output the details in JSON format.
|
||||
|
||||
Delete a Drive Label permission by specifying the label name and the principal.
|
||||
Delete a Classification Label permission by specifying the label name and the principal.
|
||||
```
|
||||
gam [<UserTypeEntity>] delete drivelabelpermission <DriveLabelNameEntity>
|
||||
gam [<UserTypeEntity>] delete classificationlabelpermission <ClassificationLabelNameEntity>
|
||||
(user <UserItem>) | (group <GroupItem) | (audience <String>)
|
||||
[adminaccess|asadmin]
|
||||
```
|
||||
|
||||
Delete a Drive Label permission by specifying the label permission name.
|
||||
Delete a Classification Label permission by specifying the label permission name.
|
||||
```
|
||||
gam [<UserTypeEntity>] remove drivelabelpermission <DriveLabelPermissionNameEntity>
|
||||
gam [<UserTypeEntity>] remove classificationlabelpermission <ClassificationLabelPermissionNameEntity>
|
||||
[adminaccess|asadmin]
|
||||
```
|
||||
## Display Drive Label Permissions
|
||||
Display permissions for a collection of Drive Label permission names.
|
||||
## Display Classification Label Permissions
|
||||
Display permissions for a collection of Classification Label permission names.
|
||||
```
|
||||
gam [<UserTypeEntity>] show drivelabelpermissions <DriveLabelNameEntity>
|
||||
gam [<UserTypeEntity>] show classificationlabelpermissions <ClassificationLabelNameEntity>
|
||||
[formatjson] [adminaccess|asadmin]
|
||||
```
|
||||
|
||||
@@ -201,7 +194,7 @@ By default, Gam displays the information as an indented list of keys and values.
|
||||
* `formatjson` - Display the fields in JSON format.
|
||||
|
||||
```
|
||||
gam [<UserTypeEntity>] print drivelabelpermissions <DriveLabelNameEntity> [todrive <ToDriveAttribute>*]
|
||||
gam [<UserTypeEntity>] print classificationlabelpermissions <ClassificationLabelNameEntity> [todrive <ToDriveAttribute>*]
|
||||
[formatjson [quotechar <Character>]] [adminaccess|asadmin]
|
||||
```
|
||||
By default, Gam displays the information as columns of fields; the following option causes the output to be in JSON format,
|
||||
@@ -213,3 +206,17 @@ 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.
|
||||
|
||||
## Process Drive File Classification Labels
|
||||
`<ClassificationLabelID>`, `<ClassificationLabelFieldID>` and `<ClassificationLabelSelectionID>` values are obtained from the commands above.
|
||||
```
|
||||
gam <UserTypeEntity> process filedrivelabels <DriveFileEntity>
|
||||
(addlabel <ClassificationLabelIDList>)*
|
||||
(deletelabel <ClassificationLabelIDList>)*
|
||||
(addlabelfield <ClassificationLabelID> <ClassificationLabelFieldID>
|
||||
(text <String>)|selection <ClassificationLabelSelectionIDList>)|
|
||||
(integer <Number>)|(date <Date>)|(user <EmailAddressList>))*
|
||||
(deletelabelfield <ClassificationLabelID> <ClassificationLabelFieldID>)*
|
||||
[nodetails]
|
||||
```
|
||||
|
||||
By default, details of the process labels are displayed, use `nodetails` to suppress this display.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
Print the current version of Gam with details
|
||||
```
|
||||
gam version
|
||||
GAM 7.00.35 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM 7.00.36 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.13.0 64-bit final
|
||||
MacOS Sonoma 14.5 x86_64
|
||||
@@ -15,7 +15,7 @@ Time: 2023-06-02T21:10:00-07:00
|
||||
Print the current version of Gam with details and time offset information
|
||||
```
|
||||
gam version timeoffset
|
||||
GAM 7.00.35 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM 7.00.36 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.13.0 64-bit final
|
||||
MacOS Sonoma 14.5 x86_64
|
||||
@@ -27,7 +27,7 @@ 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.00.35 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM 7.00.36 - https://github.com/GAM-team/GAM - pyinstaller
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.13.0 64-bit final
|
||||
MacOS Sonoma 14.5 x86_64
|
||||
@@ -64,7 +64,7 @@ MacOS High Sierra 10.13.6 x86_64
|
||||
Path: /Users/Admin/bin/gam7
|
||||
Version Check:
|
||||
Current: 5.35.08
|
||||
Latest: 7.00.35
|
||||
Latest: 7.00.36
|
||||
echo $?
|
||||
1
|
||||
```
|
||||
@@ -72,7 +72,7 @@ echo $?
|
||||
Print the current version number without details
|
||||
```
|
||||
gam version simple
|
||||
7.00.35
|
||||
7.00.36
|
||||
```
|
||||
In Linux/MacOS you can do:
|
||||
```
|
||||
@@ -82,7 +82,7 @@ echo $VER
|
||||
Print the current version of Gam and address of this Wiki
|
||||
```
|
||||
gam help
|
||||
GAM 7.00.35 - https://github.com/GAM-team/GAM
|
||||
GAM 7.00.36 - https://github.com/GAM-team/GAM
|
||||
GAM Team <google-apps-manager@googlegroups.com>
|
||||
Python 3.13.0 64-bit final
|
||||
MacOS Sonoma 14.5 x86_64
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
7.00.36
|
||||
|
||||
Updated `gam print chromeapps` to correct a trap caused by an API change.
|
||||
|
||||
7.00.35
|
||||
|
||||
Classification labels are now available for Gmail in addition to Drive.
|
||||
|
||||
@@ -25,7 +25,7 @@ https://github.com/GAM-team/GAM/wiki
|
||||
"""
|
||||
|
||||
__author__ = 'GAM Team <google-apps-manager@googlegroups.com>'
|
||||
__version__ = '7.00.35'
|
||||
__version__ = '7.00.36'
|
||||
__license__ = 'Apache License 2.0 (http://www.apache.org/licenses/LICENSE-2.0)'
|
||||
|
||||
#pylint: disable=wrong-import-position
|
||||
@@ -29839,7 +29839,7 @@ def doPrintShowChromeApps():
|
||||
app['orgUnitPath'] = orgUnitPath
|
||||
row = flattenJSON(app, simpleLists=['permissions'], delimiter=delimiter)
|
||||
if not FJQC.formatJSON:
|
||||
csvPF.WriteRow(row)
|
||||
csvPF.WriteRowTitles(row)
|
||||
elif csvPF.CheckRowTitles(row):
|
||||
csvPF.WriteRowNoFilter({'appId': app['appId'],
|
||||
'JSON': json.dumps(cleanJSON(app), ensure_ascii=False, sort_keys=True)})
|
||||
|
||||
Reference in New Issue
Block a user