PROJECT="..."
ACCOUNT="..."
# Add this value to your Sheet(s)
EMAIL="${ACCOUNT}@${PROJECT}.iam.gserviceaccount.com"
export GOOGLE_APPLICATION_CREDENTIALS=${PWD}/${ACCOUNT}.json
Interesting, so this approach still works through an explicitly created service account?
Do you think it's possible to make it work without a GCP Service Account at all?
This is one of those things that's going to be stuck in my head for a while. It's like the author gave me a hammer and now im going to go hunting for a nail.
It seems you can write to them as well... This seems much more magical than "Here is a link to a CSV, import the data yourself".
You are in for a whole lot of magical bad ideas :)
Also Google Sheets are "vulnerable" to CSV injection [1] too for "here is a link to an evil CSV, import the data yourself" scenario.
Honestly if there was a way to Auth (even basic Auth or Bearer) via classic Google Sheets, you could create a monster so easily.
https://cloud.google.com/docs/authentication/application-def...
You can:
And then: Remaining code remains unchanged.One omission from your post is that you will need to enable the Sheets service|API either using gcloud:
Or by URL: https://console.cloud.google.com/apis/library/sheets.googlea...