Skip to content

Instantly share code, notes, and snippets.

@korakot
korakot / folder_list.py
Last active January 31, 2023 15:33
List all files under a publicly-shared folder in Google Drive (in Colab), and download them
from google.colab import auth
auth.authenticate_user() # must authenticate
'''list all ids of files directly under folder folder_id'''
def folder_list(folder_id):
from googleapiclient.discovery import build
gdrive = build('drive', 'v3').files()
res = gdrive.list(q="'%s' in parents" % folder_id).execute()
return [f['id'] for f in res['files']]
@infamousjoeg
infamousjoeg / CYBRAutomation.md
Last active May 8, 2025 03:10
CyberArk Automation - Greatest Hits!