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 to build a ConnectionJson, CreationJson with Bearer token

oscarcheng
New Contributor III
New Contributor III

Vendor has built a custom platform and required to integrate with our IGA platform with Bearer token.

We built the ConnectionJson and CreationJson according to the example with Basic token but we received the following respond. It seems we are not authorized to access the system.

{
"call1":{
"headers":{
"Keep-Alive":"timeout=5, max=100",
"Server":"",
"X-Content-Type-Options":"nosniff",
"Connection":"Keep-Alive",
"Date":"Tue, 07 Nov 2023 10:00:01 GMT",
"X-Frame-Options":"SAMEORIGIN",
"X-UA-Compatible":"IE=11",
"Cache-Control":"private",
"viewport":"width=device-width, initial-scale=1",
"X-XSS-Protection":"1; mode=block",
"Content-Length":"1293",
"Content-Type":"text/html"
},
"message":{
"html":{
"head":{
"meta":{
"http-equiv":"Content-Type",
"content":"text/html; charset=iso-8859-1"
},
"style":{
"type":"text/css"
},
"title":"401 - Unauthorized: Access is denied due to invalid credentials."
},
"xmlns":"http://www.w3.org/1999/xhtml",
"body":{
"div":[
{
"h1":"Server Error",
"id":"header"
},
{
"div":{
"fieldset":{
"h2":"401 - Unauthorized: Access is denied due to invalid credentials.",
"h3":"You do not have permission to view this directory or page using the credentials that you supplied."
},
"class":"content-container"
},
"id":"content"
}
]
}
}
},
"statusCode":401,
"description":null,
"status":"Success"
}
}

 

However, if we connect on Postman, it works with same Bearer token.

I paste the ConnectionJson here. Can I have your advice?

{
"authentications": {
"acctAuth": {
"authType": "Basic",
"url": "https://<platform url>",
"httpMethod": "POST",
"httpParams": {},
"httpHeaders": {},
"httpContentType": "application/json",
"properties": {},
"authError": [],
"errorPath": "error",
"retryFailureStatusCode": [],
"maxRefreshTryCount": 5,
"tokenType": "Bearer",
"accessToken": "Bearer <token value>"
}
}
}

3 REPLIES 3

rushikeshvartak
All-Star
All-Star

Share postman screenshot and current json

 

Refer : https://docs.saviyntcloud.com/bundle/REST-v23x/page/Content/Configuring-the-Integration-for-Importin...


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

oscarcheng
New Contributor III
New Contributor III

@rushikeshvartakThanks for your helping hand!

oscarcheng_0-1699413606300.png

oscarcheng_1-1699413620494.png

 

What are parameter required for connection json needs to be passed , Authentication postman missing refer sample

{
  "authentications": {
    "userAuth": {
      "authType": "oauth2",
      "url": "https://<domain name>/api/v18.2/auth",
      "httpMethod": "POST",
      "httpParams": {
        "username": "<Username>",
        "password": "<Password>"
      },
      "httpHeaders": {
        "contentType": "application/x-www-form-urlencoded"
      },
      "httpContentType": "application/x-www-form-urlencoded",
      "expiryError": "ExpiredAuthenticationToken",
      "authError": [
        "InvalidAuthenticationToken",
        "AuthenticationFailed",
        "FAILURE",
        "INVALID_SESSION_ID"
      ],
      "timeOutError": "Read timed out",
      "errorPath": "errors.type",
      "maxRefreshTryCount": 5,
      "tokenResponsePath": "sessionId",
      "tokenType": "Bearer",
      "accessToken": "<access token>"
    }
  }
}

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