0
votes

I know how to use Google Drive API to watch user's activity with files. For that I create 'changes' objects with that url: drive/v3/changes/watch. But how to deal with Google Workspaces API? As an admin, I want to watch for all users' drives activities (adding new files, changing them). I'm as an admin, can get a list of users. And how I can watch all drives of all users in the Workspace?

1
Do you have a billing account or a private domain?Jose Vasquez
Jose, I have a billing account.goodgrief

1 Answers

1
votes

Use Google Workspace Admin SDK > Reports API

Specifically Method: activities.list on this API which allows you to retrieve all user activities given certain parameters, i.e.

Try API

https://developers.google.com/admin-sdk/reports/reference/rest/v1/activities/list?apix_params={"userKey":"all", "applicationName":"drive", "eventName":"edit", "startTime":"2021-02-22T10:26:35.000Z"}

Or

Request

GET https://admin.googleapis.com/admin/reports/v1/activity/users/all/applications/drive?eventName=edit&startTime=2021-02-22T10:26:35.000Z

The parameter eventName can be edit, add_to_folder, create, delete, ... among several events.

All Drive Audit Activity Events can be consulted here