Bulk Update Google Drive File/Folder Sharing Settings

135 views
Skip to first unread message

Semih Bekiroğlu

unread,
Jun 16, 2025, 3:36:59 PM6/16/25
to google-ap...@googlegroups.com

Hello,

I am writing to inquire about the possibility of bulk updating the sharing settings of my files in user and shared drives in my Google Workspace panel. I have the Google Drive ID information for the files. I would like to add a group mail to these files with Editor permission. Might I inquire as to the possibility of this? The owners of the files can be different users. Could you confirm whether this is possible with Gam7?

Regards



Semih Bekiroğlu

Ross Scroggs

unread,
Jun 16, 2025, 3:41:18 PM6/16/25
to google-ap...@googlegroups.com
See: https://github.com/GAM-team/GAM/wiki/Users-Drive-Permissions#manage-file-permissionssharing

On a My Drive, you will need the owner and the ID of the files.
On a Shared Drive, you will need a managr of the Shared Drive and the ID of the files.

Ross

--
You received this message because you are subscribed to the Google Groups "GAM for Google Workspace" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/google-apps-manager/CAJhJfwArGBMB60LGpzycBScdA3dQaP1tM4Z4pGAVXaXONGrZUg%40mail.gmail.com.


--

Semih Bekiroğlu

unread,
Jun 16, 2025, 4:32:17 PM6/16/25
to google-ap...@googlegroups.com
Hi, can you send me a code sample?


Semih Bekiroğlu



16 Haz 2025 Pzt, saat 22:41 tarihinde Ross Scroggs <ross.s...@gmail.com> şunu yazdı:
You received this message because you are subscribed to a topic in the Google Groups "GAM for Google Workspace" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-apps-manager/G9F_5wosOGU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-apps-man...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/google-apps-manager/CAJkvRS-dO-YYkK%2Bm7AHGUxCOPOJz9re0%2BAVZr9tXz0X%2BhB3kfw%40mail.gmail.com.

Ross Scroggs

unread,
Jun 16, 2025, 6:28:21 PM6/16/25
to google-ap...@googlegroups.com
Make a file ShareWithGroup.csv with two columns: Owner,id
In the command replace gr...@domain.com with the actual email address

gam redirect stdout ./ShareWithGroup.txt multiprocess redirect stderr stdout csv ShareWithGroup.csv gam user "~Owner" add drvefileacl "~id" gr...@domain.com role editor

Ross
----
Ross Scroggs



Semih Bekiroğlu

unread,
Jun 17, 2025, 1:47:47 PM6/17/25
to google-ap...@googlegroups.com
Hello Ross,
I used the following code script. I assigned the group emails with the roles given to the relevant folder and file.
User: I used the file owner or shared drive administrator email address.
Do you think there is a mistake?

gam csv drive.csv gam user "~user" add drivefileacl "~drive_id" "~permission_type" "~permission_email" role "~role"


CSV File

user,drive_id,permission_type,permission_email,role
us...@domain.com,1b1UWwQUEDJC8PE2Vx0YOUh12312hUGUM,group,te...@domain.com,contentmanager
us...@domain.com,1b1UWwQUEDJC8PE2VOYOU12312hppUM,group,bl...@domain2.com,writer



Ross Scroggs <ross.s...@gmail.com>, 17 Haz 2025 Sal, 01:28 tarihinde şunu yazdı:


--
Semih Bekiroğlu

Ross Scroggs

unread,
Jun 17, 2025, 1:51:12 PM6/17/25
to google-ap...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages