We're reclaiming inactive PDIs to keep them available for active builders. Learn what's changing, who's affected, and how to protect your work. Read More

Script for automatically updating Managed Oauth tokens in oauth_credential

Andrei Radules1
Giga Contributor

Hello,

I am trying to automatize the refreshing of Oauth tokens that I use in the REST Messages, so I don't have to manually trigger it once the refresh token expires.

I know the Access and Refresh token is stored in the oauth_credential. Can someone help me find a script that checks if they expire and if they do generate a new one ?

Thank you !

19 REPLIES 19

i am now receiving a {"error_description":"invalid_request, parameters should be in POST body.","error":"server_error"}

Have you tried the options from the below mentioned links?

Yes, using those method I receive {"error_description":"invalid_request, parameters should be in POST body.","error":"server_error"}

I think I am not using the request body properly

If not resolved, please share a few screenshots if possible