Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

How can we pass pre-request-script in connection json for REST appliaction

Manoj901
New Contributor
New Contributor

Hi Expert,

We are integrating workplace meta which is rest based application, we have to pass a fix access token, app_id and app_secret in the connection json and pre-request_script, in return it will generate an app_secret_proof which will be valid only for 5 min and this is working fine in postman, and to achieve this I thought of using BasicwithHMAC as authType, but it is throwing error, I am not sure where should i pass the pre-request-script in the json, I am attaching here the connection json and pre-request-script, I appreciate your help on this.

{
"authentications": {
"acctAuth": {
"authType": "BasicWithHmac",
"url": "xxxxxx",
"httpMethod": "POST",
"properties": {
"IKEY": "xxxx3",
"SKEY": "xxxx"
},
"retryFailureStatusCode": [
401,
500,
400
],
"authError": [
"InvalidAuthenticationToken",
"AuthenticationFailed",
"Authentication_MissingOrMalformed",
"Authentication_ExpiredToken"
],
"errorPath": "code",
"maxRefreshTryCount": 5,
"tokenResponsePath": "access_token",
"tokenType": "Bearer",
"accessToken": "Bearer abcd"
}
}
}

 

3 REPLIES 3

SB
Saviynt Employee
Saviynt Employee

I am not sure if using a script is supported but let me check and confirm.


Regards,
Sahil

rushikeshvartak
All-Star
All-Star

You can add script in Connection Json . Does make proof1 as call1 in connectionjson


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.

khalidakhter
Saviynt Employee
Saviynt Employee

Only the DUO and VeraCode applications are currently supported for HMAC authentication. The REST connector currently does not appear to support the aforementioned use-case. Please post this request in our Ideas portal so that we can consider it as an improvement.