Created
October 26, 2020 08:14
-
-
Save songokjesse/2887057eb9308ad099214ec3ab340629 to your computer and use it in GitHub Desktop.
Installation and instantiation of google sheet gspread dependencies
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import gspread | |
import pandas as pd | |
from oauth2client.service_account import ServiceAccountCredentials | |
from collections import OrderedDict | |
# define scope | |
scope = ['https://spreadsheets.google.com/feeds', 'https://www.googleapis.com/auth/drive'] | |
# add credentials to the account | |
creds = ServiceAccountCredentials.from_json_keyfile_name('add_json_file_here.json', scope) | |
# authorize the clientsheet | |
client = gspread.authorize(creds) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment