I am getting below error when I try to run the code
API call to reports.userUsageReport.get failed with error: Invalid string value: 'dummy@mydomain.com'. Allowed values: [all, userkey] (line 13, file "Code")
var page1 = AdminReports.UserUsageReport.get('dummy@mydomain.com', date, {
parameters: parameters.join(','),
});
The surprising thing is that from 2 days it is failing with the error mentioned above but before that it was working fine from months and was daily run. There was no change in my code.
Even when I try to access the API out of box using below url, there is no field provided to enter the userkey as an input. https://developers.google.com/admin-sdk/reports/v1/reference/userUsageReport/get