Prerequisites You need the following prerequisites:
- A Google Cloud project
- A Google account with Google Drive enabled
Before using Google APIs, you need to turn them on in a Google Cloud project. You can turn on one or more APIs in a single Google Cloud project. In the Google Cloud console, enable the Google Drive API.
To authenticate as an end user and access user data in your app, you need to create a OAuth 2.0 Client ID. In the Google Cloud console, go to Menu menu > APIs & Services > Credentials. Go to Credentials
- Click Create Credentials > OAuth client ID.
- Click Application type > Web application.
- In the Name field, type a name for the credential.
- In Authorized JavaScript origins add this: http://localhost:8000
- In Authorized redirect URLs: add this: http://localhost:8000/profile.html
- Click Create. The OAuth client created screen appears, showing your new Client ID.
==> Copy this Client ID to Client ID field present in script.js file.
In Terminal
- To clone: Enter this cmd on terminal: git clone https://github.com/jlaxman/Google-drive-extension.git
- Change directory to Google-drive-extension: Enter this cmd on terminal: cd Google-drive-extension
- After above step run this cmd on terminal: python -m http.server 8000
- Open this http://localhost:8000 in your browser, to see application running
Note: Signin with same google account as per ClientID's google account