How to get new Refresh token when an old one expires
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 hours ago
Hi Everyone,
In oauth_credential table, I see that 4 ServiceNow Request Refresh tokens are going to expire next month, but there are no access tokens with same name. when I checked Application Registry records, I found a OAuth Client Record with the same name with Redirect URL being snempappauth://.
I am not aware of where this is being used and how to authorize or refersh the token.
Any Insights into this are highly appreciated. Thanks in Advance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
it's always recommended to get access token and refresh token on every API call
with this you need not worry on the expiration of token
You can use script to obtain the refresh and access token from script
refer below links
OAuth2.0: Get new Access Token from existing Refresh Token
How to Setup OAuth2 authentication for outbound RESTMessageV2 integrations
OAuth : Script to Automate Token Request
How to generate the access token once it is expired from Business Rule?
How to get Auth Token using script when grant type is Authorization code
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader