Describe the issue/error/question
I handle the multiple user oauth flows on my backend, then I inject the google oauthdata into n8n though the api. Based on previous threads, it is all working out well when I add it, but after a while when I try to test it again (I never measured the delay) it stops working with error EAUTH
even though everything seems to be setup correctly. Is it a bug in n8n or I am setting up something wrong in n8n?
Extra info:
- The redirect url’s are all registered and valid
- All data seems to be consistent
- Adding a credential through n8n credentials tab works normally (indicates that the url’s are valid) but never tested it after a while
here is a sample from when I run n8n export:credentials --id=1 --decrypted
:
[
{
"createdAt": "2023-02-19T21:35:01.154Z",
"updatedAt": "2023-03-10T21:44:09.175Z",
"id": "1",
"name": "test-1676842500961",
"data": {
"clientId": "xxx.apps.googleusercontent.com",
"clientSecret": "xxx",
"oauthTokenData": {
"access_token": "xxx",
"token_type": "Bearer",
"refresh_token": "xxx",
"scope": "https://www.googleapis.com/auth/userinfo.profile https://www.googleapis.com/auth/userinfo.email openid https://www.googleapis.com/auth/drive.readonly",
"callbackQueryString": {
"scope": "openid https://www.googleapis.com/auth/drive.readonly https://www.googleapis.com/auth/userinfo.email https://www.googleapis.com/auth/userinfo.profile"
},
"expires_in": 3599,
"id_token": "xxx"
}
},
"type": "googleDriveOAuth2Api",
"nodesAccess": [
{
"nodeType": "n8n-nodes-base.googledriveoauth2api",
"date": "2023-02-19T21:35:01.140Z"
},
{
"nodeType": "n8n-nodes-base.googleDrive",
"date": "2023-03-10T21:44:09.172Z"
}
]
}
]
ps: all xxx
’s are valid strings I removed
What is the error message (if any)?
ERROR: UNKNOWN ERROR - check the detailed error for more information
The provided authorization grant (e.g., authorization code, resource owner credentials) or refresh token is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client.
Please share the workflow
Information on your n8n setup
- n8n version: 0.219.1
- Database you’re using (default: SQLite): default
- Running n8n with the execution process [own(default), main]: default
- Running n8n via [Docker, npm, n8n.cloud, desktop app]: npm