Skip to content

Instantly share code, notes, and snippets.

@bengineer19

bengineer19/gdrive.py

Last active Sep 13, 2020
Embed
What would you like to do?
Python Google Drive API
import json
import os
from google.oauth2 import service_account
service_account_info = json.loads(os.getenv('GDRIVE_AUTH'))
SCOPES = ['https://www.googleapis.com/auth/drive.metadata.readonly']
creds = service_account.Credentials.from_service_account_info(
service_account_info, scopes=SCOPES)
service = build('drive', 'v3', credentials=creds)
# Do epic things
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.