integration_google icon indicating copy to clipboard operation
integration_google copied to clipboard

"401 Unauthorized" after a week from initial setup

Open shalak opened this issue 1 year ago • 5 comments

Exactly 7 days ago, I've setup the Google Integration 1.0.9 in a fresh nextcloud-aio 25.0.3 installation.

Whole week I've experienced an issue with import process getting stuck. I was simply canceling and re-starting the process, and with every attempt I got a little bit more of data from Google Drive/Photos.

Today, when I wanted to go through the usual routine mentioned above, I couldn't - there was a toasty message mentioneing 401 showing up on my profile, and admin logs are showing:

Google API ServerException|ClientException error : Client error: `GET https://photoslibrary.googleapis.com/v1/albums?pageSize=50` resulted in a `401 Unauthorized` response: { "error": { "code": 401, "message": "Request had invalid authentication credentials. Expected OAuth 2 access (truncated...) status code: 401 body: { "error": { "code": 401, "message": "Request had invalid authentication credentials. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.", "status": "UNAUTHENTICATED" } } 

In the meantime, 0,92% drive.files.get errors appeared in Google Console: image

Am I doing something wrong? Like the token expires after a week, or something?

Also, what more important - can I safely "Disconnect from Google" in my profile and re-authenticate again, and the whole process will be able to pick up where it left off?

shalak avatar Feb 06 '23 10:02 shalak

You gotta enable the apis in the google cloud dashboard, check the instructions in the admin settings.

anoosa1 avatar May 16 '23 02:05 anoosa1

I did enable all of them.

shalak avatar May 23 '23 15:05 shalak

I did enable all of them.

after you do it you may need to logout of google from nextcloud and reauth.

anoosa1 avatar May 24 '23 01:05 anoosa1

Hello :wave: This issue appears to have had no activity for 3 months. We cannot keep track of whether individual issues have resolved themselves or still require attention without user interaction. We're thus adding the stale label to this issue to schedule it for getting closed in 5 days time. If you believe this issue is still valid and should be fixed, you can add a comment or remove the label to avoid it getting closed.

Cheers :blue_heart:

github-actions[bot] avatar Aug 22 '23 01:08 github-actions[bot]

This issue was closed because it has been stalled for 5 days with no activity.

github-actions[bot] avatar Aug 27 '23 01:08 github-actions[bot]