Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Access token only lasts a day. #171

Open
andrewhumble opened this issue Nov 23, 2023 · 1 comment
Open

Access token only lasts a day. #171

andrewhumble opened this issue Nov 23, 2023 · 1 comment

Comments

@andrewhumble
Copy link

Mintable is working for me until the access token expires after roughly a day, giving me the error: "No refresh token is set". Is this a common issue? I don't see anything about it in the docs. Any help here would be greatly appreciated.

Here's the full stacktrace I'm getting:

Error: No refresh token is set. at OAuth2Client.refreshTokenNoCache (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:162:19) at OAuth2Client.refreshToken (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:143:25) at OAuth2Client.getRequestMetadataAsync (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:266:28) at OAuth2Client.requestAsync (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:339:34) at OAuth2Client.request (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:333:25) at createAPIRequestAsync (/Users/andrewhumble/mintable/node_modules/googleapis-common/build/src/apirequest.js:268:27) at Object.createAPIRequest (/Users/andrewhumble/mintable/node_modules/googleapis-common/build/src/apirequest.js:46:16) at Resource$Spreadsheets.get (/Users/andrewhumble/mintable/node_modules/googleapis/build/src/apis/sheets/v4.js:145:44) at GoogleIntegration.getSheets (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:69:18) at GoogleIntegration.<anonymous> (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:302:55) at step (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:33:23) at Object.next (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:14:53) at /Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:8:71 at new Promise (<anonymous>) at __awaiter (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:4:12) at GoogleIntegration.updateSheet (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:297:87) { [stack]: 'Error: No refresh token is set.\n' + ' at OAuth2Client.refreshTokenNoCache (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:162:19)\n' + ' at OAuth2Client.refreshToken (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:143:25)\n' + ' at OAuth2Client.getRequestMetadataAsync (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:266:28)\n' + ' at OAuth2Client.requestAsync (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:339:34)\n' + ' at OAuth2Client.request (/Users/andrewhumble/mintable/node_modules/google-auth-library/build/src/auth/oauth2client.js:333:25)\n' + ' at createAPIRequestAsync (/Users/andrewhumble/mintable/node_modules/googleapis-common/build/src/apirequest.js:268:27)\n' + ' at Object.createAPIRequest (/Users/andrewhumble/mintable/node_modules/googleapis-common/build/src/apirequest.js:46:16)\n' + ' at Resource$Spreadsheets.get (/Users/andrewhumble/mintable/node_modules/googleapis/build/src/apis/sheets/v4.js:145:44)\n' + ' at GoogleIntegration.getSheets (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:69:18)\n' + ' at GoogleIntegration.<anonymous> (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:302:55)\n' + ' at step (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:33:23)\n' + ' at Object.next (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:14:53)\n' + ' at /Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:8:71\n' + ' at new Promise (<anonymous>)\n' + ' at __awaiter (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:4:12)\n' + ' at GoogleIntegration.updateSheet (/Users/andrewhumble/mintable/lib/integrations/google/googleIntegration.js:297:87)', [message]: 'No refresh token is set.' }

@logan-life
Copy link

You should have a refreshToken key/value pair in your mintable.jsonc config. If you don't, consider re-doing mintable google-setup workflow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants