domainwidedelegation.comStart free

Use casesDocuments and Drive

Schedule shared drive usage reports with delegation

Automate shared drive storage and activity summaries across tenants, so admins spot growth and orphaned content before limits hit.

Who it is forIT operations or compliance teams overseeing shared drive sprawl.
APIsDrive API
Typical scopesdrive.readonly

The problem

Shared drives grow unchecked. Storage costs climb, and nobody can see what is filling up space or which drives are abandoned. Manual audits miss drives and never catch up with growth.

How it works

  1. Enumerate all shared drives using the Drive API with delegated access.
  2. For each drive, list files and aggregate size, owner, and last activity.
  3. Write usage data to a central sheet or dashboard for ongoing review.
  4. Schedule the process weekly or monthly to catch trends.
  5. Alert when thresholds are crossed (e.g., storage, inactivity).

What changes

Admins have a current picture of shared drive usage, making it possible to act before hitting storage quotas or compliance issues.

The trap in this one. Drive API's "list files" call silently omits files that are pending deletion or in the drive trash, but these still count toward storage usage. If you only sum listed files, reported usage will always understate reality—use the drives.get 'capabilities' and 'quotaBytesUsed' fields for actual totals. This is not documented in the basic list API reference and leads to misreporting if missed.

Watch it explained

Google Workspace DLP (Data Loss Prevention) | Tricent Demo and Walkthrough” — The Cloud Nerd on YouTube. Third-party video, included because it covers this ground well. We are not affiliated with the channel.

Questions people ask

How can I identify abandoned drives?

Look for drives where all files are old, or where activity (modification, creation) hasn't occurred in a set period. The Drive API's activity history is partial, so combine file timestamps and membership changes.

Does drive.readonly allow reading all metadata required?

Yes, for usage and file listing, but not for file contents. For content inspection, a broader scope is needed, but that's rarely justified for reporting.

Want this built?

This is a pattern we run in production. We will set up the delegation and build this on top of it — $500 per hour, most of it working the same day.

Talk to us Or read the setup guide

Related use cases

Create a client folder structure the moment a deal closes

Provision a consistent Drive folder tree, seeded with templates and shared with the right people, automatically.

Generate documents from a template and real data

Produce agreements, letters and reports from a Docs template with fields filled from your systems.

Sort incoming files into the right place automatically

Watch a drop folder, work out what each file is, and file it where it belongs with a consistent name.