Your company is one delete away from losing everything
Here is the problem. An employee leaves, their Google account gets deleted, and their Drive goes with it. Not archived. Not transferred. Gone.
Most teams assume the company owns those files. It doesn't. In Google Workspace, files in My Drive belong to the user who created them. Delete the user without a transfer and the files follow.
The fix
Move everything to a Shared Drive before offboarding. Shared Drives are owned by the organisation, so ownership shifts automatically and nothing depends on the departing account.
The process has three parts:
- Recreate the folder structure. Walk the user's My Drive and build the same tree inside the Shared Drive, so nothing lands in a flat pile.
- Transfer the files, not downloads. Use the Drive API to move each file into its new parent. No download and re-upload, so version history, comments and sharing links survive.
- Verify, then offboard. Compare counts on both sides before the account is touched.
Why automate it
Done by hand this is a checklist someone forgets on a busy day. On a platform with 120k+ users and constant campaign churn it is not optional. I rebuilt the flow as a Temporal workflow: the parent workflow handles the account, child workflows handle the Drive transfer, and every step retries on its own if the API hiccups. Since then, departing users' files move to the company first, with zero data loss.
No chasing. No surprises. Nobody notices work like that, and that is the point.