It generates token with life duration = 1 hour
See original GitHub issueI’ve created “Credentials.json” file as per instructions.
Then I am running the command to generate Token:
node ..\..\node_modules\gmail-tester\init.js .\credentials.json gmail_token.json test@gmail.com
It successfully creates Token, BUT it’s life time is just 1 hour.
{
"access_token": "ya29.a0AfH6SMDwy2 ... xMze5YfDMru-CYaM",
"refresh_token": "1//09boFIYyEL0w3Cg ... UKq7eNZHeSKxIv3MyZqI",
"scope": "https://www.googleapis.com/auth/gmail.readonly",
"token_type": "Bearer",
"expiry_date": 1610372897000
}
How extend token life time (to at least half of the year)?
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (4 by maintainers)
Top Results From Across the Web
Configurable token lifetimes - Microsoft Entra
ID tokens, SAML2 tokens: 1 hour. Minimum: 10 minutes; Maximum: 1 day. Refresh and session token lifetime policy properties. Refresh and session ...
Read more >Can I request a token with a lifespan shorter than 1 hour?
Yes, you can configure your Azure Active Directory token lifetime minimum 10 minutes. You could use following power-shell command to create ...
Read more >Update Access Token Lifetime - Auth0
Locate the Token Expiration (Seconds) field, and enter the appropriate access token lifetime (in seconds) for the API. Default value is 86,400 seconds...
Read more >Access Token Lifetime - OAuth 2.0 Simplified
Typically services using this method will issue access tokens that last anywhere from several hours to a couple weeks. When the service issues ......
Read more >Token types | Authentication - Google Cloud
generateIdToken method to generate an access token for a service account with a lifetime of up to 12 hours. You can't create access...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
According to this, it looks like the access token is now expiring after one hour. I’ll expose a function to refresh the access token in the coming days.
Thank you for bringing this to my attention.
Can you guys please confirm the new method solves the issue?