Google Sheets Import & Export avatar

Google Sheets Import & Export

Try for free

No credit card required

View all Actors
Google Sheets Import & Export

Google Sheets Import & Export

lukaskrivka/google-sheets
Try for free

No credit card required

Import data from datasets or JSON files to Google Sheets. Programmatically process data in Sheets. Easier and faster than the official Google Sheets API and perfect for importing data from scraping.

Do you want to learn more about this Actor?

Get a demo
EP

Error invalid_grant after few days

Closed

exclusive_plants opened this issue
2 years ago

The export works fine for a few days after authorizing, but after some time I get invalid_grant. Is there something I'm missing in the configuration?

2022-10-08T04:30:16.170Z INFO System info {"apifyVersion":"2.0.7","apifyClientVersion":"1.4.2","osType":"Linux","nodeVersion":"v16.8.0"} 2022-10-08T04:30:16.173Z WARN You are using an outdated version (2.0.7) of Apify SDK. We recommend you to update to the latest version (2.2.2). 2022-10-08T04:30:16.176Z Read more about Apify SDK versioning at: https://help.apify.com/en/articles/3184510-updates-and-versioning-of-apify-sdk 2022-10-08T04:30:16.876Z Input: 2022-10-08T04:30:16.889Z {} 2022-10-08T04:30:17.090Z We found tokens saved in our store. No need to authenticate again. 2022-10-08T04:30:17.092Z using stored tokens 2022-10-08T04:30:17.774Z ERROR 2022-10-08T04:30:17.777Z Error: invalid_grant 2022-10-08T04:30:17.779Z at Gaxios._request (/usr/src/app/node_modules/gaxios/build/src/gaxios.js:129:23) 2022-10-08T04:30:17.780Z at processTicksAndRejections (node:internal/process/task_queues:96:5) 2022-10-08T04:30:17.783Z at async OAuth2Client.refreshTokenNoCache (/usr/src/app/node_modules/google-auth-library/build/src/auth/oauth2client.js:172:21) 2022-10-08T04:30:17.785Z at async OAuth2Client.getRequestMetadataAsync (/usr/src/app/node_modules/google-auth-library/build/src/auth/oauth2client.js:259:17) 2022-10-08T04:30:17.787Z at async OAuth2Client.requestAsync (/usr/src/app/node_mo... [trimmed]

lukaskrivka avatar

Hello, I was reworking the authorization process because Google changed the rules. It should not impact old users but it will impact any new authorizations.

invalid_grant usually means that you are using wrong account for that sheet. If you cannot get rid of it, probably just delete the google-auth-tokens kv store and go through the authorization again.

EP

exclusive_plants

2 years ago

Hi, thanks for quick reply. Just to clarify the everything works fine for a few days, then I receive the invalid_grant and have to delete the tokens and authorize again manually.

lukaskrivka avatar

Thanks. I never encountered this issue before, it is possible that Google now decided to allow the tokens to live only for several days. Unfortunately, there isn't probably much I can do with it.

Developer
Maintained by Apify

Actor Metrics

  • 46 monthly users

  • 29 stars

  • 82% runs succeeded

  • 17 days response time

  • Created in Jan 2019

  • Modified 5 months ago

Categories