Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Readme: add activate-service-account step #14

Merged
merged 1 commit into from
Oct 24, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,16 @@ To connect DuckDB to Google Sheets, you’ll need to create a Service Account th
8. Go to the **Keys** tab, then click **Add Key** > **Create New Key**.
9. Choose **JSON**, then click **Create**. The JSON file will download automatically.
10. Download and install the [gcloud CLI](https://cloud.google.com/sdk/docs/install).
11. Run the following command to generate an access token:
11. Run the following command to login to the gcloud CLI with the Service Account using the newly created JSON file
```bash
gcloud auth activate-service-account --key-file /path/to/key/file
```
12. Run the following command to generate an access token:
```bash
gcloud auth print-access-token --scopes=https://www.googleapis.com/auth/spreadsheets
```
12. Open your Google Sheet and share it with the Service Account email.
13. Run DuckDB and load the extension
13. Open your Google Sheet and share it with the Service Account email.
14. Run DuckDB and load the extension

This token will periodically expire - you can re-run the above command again to generate a new one.

Expand Down
Loading