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

Account Entitlement Mapping for REST Connector

rituparna_pwc
Regular Contributor
Regular Contributor

Hi,

we are trying to Import accounts using REST Connector. We are able to import accounts and entitlements from the response but unable to map accounts and entitlements. 

The designationcode key pair contains the entitlement value in comma separated form. like "ent1,ent2" .

ent1 and ent2 are entitlements within system. how to map it?

API Response

{
    "Users": [
        {
            "EmployeeID""tchee",
            "EmployeeName""Tee Chee",
            "EmailAddress""TChee@test.com",
            "DesignationCodes"'Ent3,Ent4"
        },
        {
            "EmployeeID""thanks",
            "EmployeeName""Tom Hanks,
            "EmailAddress""tom.hanks@test.com",
            "DesignationCodes""Ent1,Ent2"
        },

AccountImportJSON

{
   "accountParams": {
     "connection": "userAuth",
"includeExistingInActiveAccounts": true,
     "processingType": "SequentialAndIterative",
     "call": {
       "call1": {
"callOrder": 0,
"stageNumber": 0,
"http": {
 
"httpHeaders": {
"Authorization": "${access_token}"
},
"httpContentType": "application/json",
"httpParams": "{\"c\":\"sg\",\"d\":\"\"}",
"httpMethod": "GETWITHBODY"
},
"listField": "Users",
"keyField": "accountID",
"colsToPropsMap": {
"accountID": "EmployeeID~#~char",
"name": "EmployeeID~#~char",
"status": "StatusCode~#~char",
"lastlogondate": "LastLoginTime~#~char",
"customproperty2": "DepartmentName~#~char",
"customproperty1": "EmployeeName~#~char",
"customproperty4": "EmailAddress~#~char",
"customproperty5": "MobileNumber~#~char",
"customproperty6": "DesignationCodes~#~char",
"customproperty7": "StatusCode~#~char",
"customproperty31": "STORE#ACC#ENT#MAPPINGINFO~#~char"
}
}
     },
 
"acctEntMappings": {
"Designations": {
"listPath": "Users.DesignationCodes",
"keyField": "entitlement_value"
}
}
   },
   "entitlementParams": {
     "connection": "userAuth",
     "processingType": "SequentialAndIterative",
     "entTypes": {
       "Designations": {
         "entTypeOrder": 0,
         "call": {
           "call1": {
"connection": "userAuth",
             "callOrder": 0,
             "stageNumber": 0,
             "http": {
               "httpHeaders": {
                 "Authorization": "${access_token}"
               },
              "httpContentType": "application/json",
"httpParams": "{\"c\":\"sg\",\"d\":\"\"}",
"httpMethod": "GETWITHBODY"
             },
             "listField": "Designations",
             "keyField": "entitlementID",
             "colsToPropsMap": {
               "entitlementID": "DesignationCode~#~char",
               "entitlement_value": "DesignationCode~#~char",
   "displayname": "DesignationCode~#~char",
   "description": "DesignationName~#~char"
             },
"disableDeletedEntitlements": true
           }
         }
       }
     }
   },
   "acctEntParams": {
"processingType": "acctToEntMapping"
}
 }
 
[This message has been edited by moderator to mask url]
7 REPLIES 7

SB
Saviynt Employee
Saviynt Employee

Though I have not implemented this type of integration before but can you check if there is any other api available that gives the account to entitlement correlation mapping.


Regards,
Sahil

rituparna_pwc
Regular Contributor
Regular Contributor

@SB , this API : "https://domain.com/webapistg/api/Saviynt/GetUserList" gives account to entitlement  mapping as per below payload, the problem is if you look at designationcode field of each user, it comes as a string in comma separated value. How do we map this string in accountentparam?

{
    "Users": [
        {
            "EmployeeID""tchee",
            "EmployeeName""Tee Chee",
            "EmailAddress""TChee@test.com",
            "DesignationCodes"'Ent3,Ent4"
        },
        {
            "EmployeeID""thanks",
            "EmployeeName""Tom Hanks,
            "EmailAddress""tom.hanks@test.com",
            "DesignationCodes""Ent1,Ent2
        }}

SB
Saviynt Employee
Saviynt Employee

Let me check on this and will update you.


Regards,
Sahil

rituparna_pwc
Regular Contributor
Regular Contributor

Thanks @SB 

SB
Saviynt Employee
Saviynt Employee

Can you try with below and see if it works.

"listField": "Users",
"acctIdPath": "EmployeeID",
"entListField": "DesignationCodes",
"entIdPath": ".",
"entKeyField": "entitlementID"


Regards,
Sahil

Jyoti1
Regular Contributor
Regular Contributor

Hi 

Can you please share your working json

rituparna_pwc
Regular Contributor
Regular Contributor

Hello @Jyoti1 ,

Comma separated strings in entitlements are not supported by Saviynt, we made the target system to send Array of Strings.

The working JSON is

{
"accountParams": {
"connection": "userAuth",
"includeExistingInActiveAccounts": true,
"processingType": "SequentialAndIterative",
"call": {
"call1": {
"callOrder": 0,
"stageNumber": 0,
"http": {
"url": "https://xxxxxx/webapistg/api/Saviynt/GetUserList",
"httpHeaders": {
"Authorization": "${access_token}"
},
"httpContentType": "application/json",
"httpMethod": "GET"
},
"listField": "Users",
"keyField": "accountID",
"colsToPropsMap": {
"accountID": "EmployeeID~#~char",
"name": "EmployeeID~#~char",
"status": "StatusCode~#~char",
"lastlogondate": "LastLoginTime~#~char",
"customproperty2": "DepartmentName~#~char",
"customproperty1": "EmployeeName~#~char",
"customproperty4": "EmailAddress~#~char",
"customproperty5": "MobileNumber~#~char",
"customproperty6": "DesignationCodes~#~char",
"customproperty7": "StatusCode~#~char",
"customproperty8": "Country~#~char",
"customproperty31": "STORE#ACC#ENT#MAPPINGINFO~#~char"
}

}
},
"acctEntMappings": {
"Designations": {
"listPath": "DesignationCodes",
"idPath": "",
"keyField": "entitlementID"
}
}
},
"entitlementParams": {
"processingType": "SequentialAndIterative",
"entTypes": {
"Designations": {
"entTypeOrder": 0,
"call": {
"call1": {
"connection": "userAuth",
"callOrder": 0,
"stageNumber": 0,
"http": {
"httpHeaders": {
"Authorization": "${access_token}"
},
"url": "https://xxxxx/webapistg/api/Saviynt/GetDesignationList",
"httpContentType": "application/json",
"httpMethod": "GET"
},
"listField": "Designations",
"keyField": "entitlementID",
"colsToPropsMap": {
"entitlementID": "DesignationCode~#~char",
"entitlement_value": "DesignationCode~#~char",
"displayname": "DesignationCode~#~char",
"description": "DesignationName~#~char"
},
"disableDeletedEntitlements": true

}
}
}
}
},
"acctEntParams": {
"processingType": "acctToEntMapping"
}
}