REST Connector Basic Authentication throws error Connection "Access Token Expired" error

Devin
New Contributor II
New Contributor II

Hello,

We have been running into an issue trying to integrate a new connector for a vendor API in Saviynt without much success. Using Postman, all requests appear to return successfully, but when supplying all the info in the connectorJSON and successfully saving the connection details, after a short period of time, the handshake seems to throw a 403 token error displayed when looking through the logs. It also appears the refresh token is causing the bearer to error, but I could be mistaken.  Any help would be appreciated.

(Here's some errors found in the logs, will also attach.)

007 [quartzScheduler_Worker-4] DEBUG rest.RestProvisioningService - responseError : null\n"
007 [quartzScheduler_Worker-4] DEBUG rest.RestProvisioningService - isAuthError: false\n"

Thanks,
Devin

3 REPLIES 3

rushikeshvartak
All-Star
All-Star

You have not configured json itself use below

 

{"authentications": {
"acctAuth": {
"authType": "oauth2",
"url": "https://us2.api.concursolutions.com/oauth2/v0/token",
"httpMethod": "POST",
"httpHeaders": {
"contentType": "application/x-www-form-urlencoded",
"X-ConsumerKey": "<client id>",
"Accept": "application/json"
},
"properties": {
"grant_type": "refresh_token",
"client_secret": "CLIENT_SECRET_VALUE",
"client_id": "CLIENT_ID_VALUE",
"refresh_token": "ad"

},
"httpContentType": "application/x-www-form-urlencoded",
"expiryError": "Forbidden. Please check your Instance URL and OAuth token",
"authError": [
"Forbidden",
"Forbidden. Please check your Instance URL and OAuth token"
],
"timeOutError": "Read timed out",
"errorPath": "Error.Message",
"maxRefreshTryCount": 1,
"tokenResponsePath": "access_token",
"tokenType": "Bearer",
"accessToken": "Bearer abdc"
}
}
}

Hey, thanks for the reply.  I should have mentioned that the the json supplied was similar to our use-case with all the Auth info removed.  Here is the last connectionJSON we have tested, I will include the error response from Saviynt.  Thanks.

{
"authentications": {
"acctAuth": {
"authType": "oauth2",
"url": "https://<url>/oauth2/v0/token",
"httpMethod": "POST",
"httpParams": {
"grant_type": "refresh_token",
"client_secret": <client_secret>,
"client_id": <client_id>,
"refresh_token": <refresh_token>
},
"httpHeaders": {
"contentType": "application/x-www-form-urlencoded"
},
"httpContentType": "application/x-www-form-urlencoded",
"expiryError": "ExpiredAuthenticationToken",
"authError": ["invalid_grant"],
"timeOutError": "Read timed out",
"errorPath": "error.code",
"maxRefreshTryCount": 5,
"tokenResponsePath": "access_token",
"tokenType": "Bearer",
"accessToken": "Bearer abcd"
}
}
}

concurImportError_v2.png

 

Devin
New Contributor II
New Contributor II

Hey, thanks for the reply.  We solved our issue by adding the 'retryFailureStatusCode 401' to the connectionJSON which appears to fixed the issue.  Thanks again for the help.