Questions tagged [googlesheets4]

Access Google Sheets using the Sheets API V4

googlesheets4 provides an R interface to Google Sheets via the Sheets API v4. It is a reboot of an earlier package called googlesheets.

82 questions
14
votes
4 answers

Connect to googlesheets via shiny in R with googlesheets4

I'm trying to use an updated version of this example to connect to a private googlesheet via shiny, and deploy this app on the shinyapps.io server. The user is not required to authenticate to a google account as the app uses a specified pre-existing…
CCID
  • 1,368
  • 5
  • 19
  • 35
9
votes
1 answer

How to automatically select pre - authorized account in googlesheets4 in R when scheduling code?

I'm trying to figure out what would be the method to automatically allow the googlesheet4 package to choose my pre - authorized account to download a particular google sheet. For example - I want to run the following once a day…
sky_megh
  • 135
  • 6
8
votes
4 answers

Client doesn't have sufficient permission

I am currently running library(googlesheets4) sheets_auth() dat=read_sheet("https://docs.google.com/spreadsheets/d/1R9XuH9Wej-p6HdkFGV2IsHuCmA9w0s7M3-jzE3S-Qrs/edit#gid=950673024", sheet="Summary", range=cell_rows(1:777)) and getting the…
Daniel Callow
  • 101
  • 1
  • 6
5
votes
1 answer

Authorizing non-interactive use of googlesheets through Shiny app using googlesheets4

I know there are a few other similar questions floating around SO (e.g., here and here), but I thought I'd try again, as the others have not gotten many answers. I have a Shiny app that allows its users to provide input through the app, but these…
phalteman
  • 3,442
  • 1
  • 29
  • 46
4
votes
1 answer

R package googlesheets4 returns Client error: (429) RESOURCE_EXHAUSTED when reading a public sheet

library(googlesheets4) url_rls <- "https://docs.google.com/spreadsheet/d/17eJ05pg6fkzKlwwiWn0ztdMvzBX9pGx3q6w7h3_vJw4/" gs4_deauth() read_sheet(url_rls) Returns this error sometimes, but not always. Do I need to login just to read a public…
Zoltan
  • 760
  • 4
  • 15
4
votes
1 answer

How to send gs4_create() ouput directly to a googledrive folder

I am trying to upload hundreds of googlesheets using the new R googlesheets4 package using the function gs4_create. I can successfully upload files in the root of the google drive but fail to see how I can send it inside a pre existing folder on…
Lazarus Thurston
  • 1,197
  • 15
  • 33
4
votes
1 answer

Non-interactive authentication for googlesheets4 using json path

Although it's not my main language, I'm using R to post results from a daily ETL into a Google Sheets worksheet. Because this is going to be a scheduled job that runs in perpetuity, I'm hesitant to use the interactive flow for authenticating Google…
4
votes
0 answers

`sheets_auth` (from `googlesheets4`) doesn't work with a token created with `googleAuthR` package

I want to create an shiny app that analyses some data from a google sheet. It will be deployed on the server. The sheet is only available for users within the company, so I need to implement authentication (api key approach won't work here) and as I…
jjankowiak
  • 3,010
  • 6
  • 28
  • 45
3
votes
2 answers

Googlesheets quota limit issues - possible failure to use API key

We are currently using google sheets for a research project on crowd forecasts for Covid-19 case and death numbers. Google Sheets is used for convenience, but we are often running into quota limit issues - even though the number of users we have…
Nikos Bosse
  • 144
  • 11
3
votes
2 answers

Struggling to use my own API key with googlesheets4 in shinyapps.io

I've got googlesheets4 working in a shinyapps.io with the following code: gs4_auth( email = "me@email.com", path = NULL, scopes = "https://www.googleapis.com/auth/drive", cache = "path_to_cache", use_oob = FALSE, token = NULL) I run this locally,…
Jimbo Mahoney
  • 220
  • 2
  • 9
3
votes
2 answers

Error trying to connect R to Googlesheet using package googlesheets4: Can't get Google credentials

I've a problem while trying to connect R with Googlesheet (package googlesheets4): Error:Can't get Google credentials. Are you running googlesheets4 in a non-interactive session? Consider: *gs4_deauth() to prevent the attempt to get credentials. *…
Agnieszka
  • 81
  • 5
3
votes
1 answer

R/googlesheets4 non-interactive session

When I use googlesheets4 in R, I use sheets_auth() in the console and it works fine. But when I try to run it in R markdown, and when I try to knit, I cannot seem to get the credentials. Can someone walk me through the process? I've gone to the…
3
votes
0 answers

Can't knit Rmd when using googlesheets4

I am attempting to knit a .Rmd file that uses googlesheets4, but the execution fails every time. Here's my code where it fails: for (package in c('tidyverse', 'googledrive', 'googlesheets4')) { if (!require(package, character.only=T, quietly=T))…
millie0725
  • 359
  • 2
  • 12
3
votes
1 answer

Automatic Google Sheets authorization in RShiny

I have an RShiny app that I had published online without any issues until this week. The app uses data stored in a Google Drive account, thus making use of the googlesheets package. When the app was working fine, I used gs_auth() to initially…
Tyryn
  • 43
  • 5
3
votes
1 answer

Googlesheets4 does not read my Spreadsheets

I am using googlesheets4 to store Shiny data. I could reach my googleDrive but I am not able to read any sheet. I also tried "sheet_examples" but I got the same error message, see below. Here is a piece of code that gives the error: I…
1
2 3 4 5 6