From 435388aa0ba8bae3b3428f955d0d14ec66648ecb Mon Sep 17 00:00:00 2001 From: Ross Scroggs Date: Thu, 27 Jun 2024 10:11:06 -0700 Subject: [PATCH] gam report updates --- docs/GamUpdates.md | 11 +++++++++++ docs/Reports.md | 16 ++++++++++++---- src/GamCommands.txt | 4 ++-- src/GamUpdate.txt | 11 +++++++++++ src/gam/__init__.py | 46 +++++++++++++++++++++++++++++---------------- 5 files changed, 66 insertions(+), 22 deletions(-) diff --git a/docs/GamUpdates.md b/docs/GamUpdates.md index 8b315b73..82d31aa5 100644 --- a/docs/GamUpdates.md +++ b/docs/GamUpdates.md @@ -21,6 +21,17 @@ Thanks to jay, added the following Colab License SKUs: Thanks to Jay, updated `gam print|show admins` to properly display addresses of service accounts with admin role assignments. +Added option `limitdatechanges ` to `gam report users|customers`. + +If no report is available for the specified date, can an earlier date be used? +* `limitdatechanges -1' - Back up to earlier dates to find report data; this is the default. +* `limitdatechanges 0 | nodatechange' - Do not report on an earlier date if no report data is available for the specified date. +* `limitdatechanges N' - Back up to earlier dates to find report data; do not back up more than N times. + +By default, when `gam report user user ` is specified and no report data is available, there is no output. +If `csv_output_users_audit = true` in `gam.cfg`, then a row with columns `email,date` will be displayed +where `date` is the earliest date for which report data was requested. + ### 6.77.02 Cleaned up problems with some of the new Chat API asadmin commands. diff --git a/docs/Reports.md b/docs/Reports.md index a8e5f407..def6e4b6 100644 --- a/docs/Reports.md +++ b/docs/Reports.md @@ -234,7 +234,7 @@ Customer reports are generally available up to two days before the current date. gam report customers|customer|domain [todrive *] [(date )|(range )| yesterday|today|thismonth|(previousmonths )] - [nodatechange|(fulldatarequired all|)] + [(nodatechange | limitdatechanges ) | (fulldatarequired all|)] [(fields|parameters )|(services )] [noauthorizedapps] ``` @@ -247,7 +247,9 @@ Specify the report date; the default is today's date. * `previousmonths ` - A number in the range 1 to 6 indicating calendar months previous to the current month; there is an API call per date If no report is available for the specified date, can an earlier date be used? -* `nodatechange` - Do not report on an earlier date if no report is available for the specified date. +* `limitdatechanges -1' - Back up to earlier dates to find report data; this is the default. +* `limitdatechanges 0 | nodatechange' - Do not report on an earlier date if no report data is available for the specified date. +* `limitdatechanges N' - Back up to earlier dates to find report data; do not back up more than N times. If only partial report data is available for the specified date and applications, can an earlier date be used? * `fulldatarequired all` - Back up to an earlier date to get complete data until all applications have full report data @@ -328,7 +330,7 @@ gam report users|user [todrive *] [allverifyuser ] [(date )|(range )| yesterday|today|thismonth|(previousmonths )] - [nodatechange|(fulldatarequired all|)] + [(nodatechange | limitdatechanges ) | (fulldatarequired all|)] [filtertime.*