Google Drive API for receiving access request notification

Viewed 105

I am trying to integrate with Google Drive such that I can receive a notification whenever someone tries to request access for any file in my drive. But, I could not find any such API for that.

I have integrated with Google Drive Watch Changes API, but it doesn't push any event for access requests, otherwise, it works fine. I have also checked List Changes and Query Activity api whether it has any change for such case, but I could not find any such change/activity.

I found out that Slack can receive such notifications which means it is possible somehow. Kindly help, if you know how can it be done.

1 Answers

I assume that your goal is to record each time that someone opens any file in your Drive. If my assumption is correct, then you could use Apps Script API to accomplish your goal. You should create an onOpen() trigger that saves the user interaction (you may want to send yourself an email with MailApp), and apply it to every file that you want to monitor. You can take these project management examples as a reference. Please, ask me any additional doubt about this approach.

Related