Webservice connector custom attributes

Hi All,
I have one application which is webseries and there is an array of list inside account i need to add this as new attribute. I need attribute which combines roles and id mentioned in the below example could anyone please let me know how to concat those attributes I tried to add after rule I got roles list_id list required as mentioned below

required custom attribute:

roleperid:[role1_122, role2_123]

Ex:


[{
		name: test,
		Email: test @gmail.com
		Account: [{
				role: role1
				Id: 122
			},
			{
				role: role2,
				Id: 123
			}
		],
		name: test1,
		Email: test1 @gmail.com
		Account: [{
				role: role2
				Id: 147
			},
			{
				role: role3,
				Id: 187
			}
		]
	]
	

Hi @manasaP! I assume that the role id is directly related to role (which is more like a name/display-name for the role)?

If so, the ideal way to go would be to configure group aggregation for roles to pull in all the role metadata (like the name, description, etc.), and map that to the Account schema roles attribute which just pulls in the Id attribute value. IIQ will internally handle resolving the account entitlement to the aggregated role in the entitlement catalog to add the desired additional context (much like how it does with AD and LDAP apps).

Hi Brian,
Thanks for the response this is for account aggregation itself not group aggregation. Account attribute should be role_id as this should be passed to other application this API is input to SailPoint.

Thanks & Regards,
Manasa.

Alrighty - would you mind sharing the WebServiceAfterOperationRule that you tried to create? These rules can be a bit finnicky.

Hi Manasa,

I guess what you are trying to do is create a new entitlement attribute in Sailpoint( roleperid) to meet the application entitlement structure.
Create a new attribute in Application Schema and keep it as Multi-Valued Attribute (If you are planning to use this attribute as entitlement then mark entitlement as well). Instead of using After Rule try leveraging the Customization Rule. You will be able to concatenate values from 2 attributes and update the new attribute.

Sample Code :

if (object != null) {
  List rolePerId = new ArrayList();
  List idList = (List) object.getAttribute("Id");
  List roleList = (List) object.getAttribute("role");
  if (idList == null || roleList == null
      || idList.size() != roleList.size()) {
    return object;
  }
  int noOfRoles = roleList.size();
  for (int i = 0; i < noOfRoles; i++) {
    String rolePerId = roleList.get(i) + "_" + idList.get(i);
  }
  object.setAttribute("rolePerId", rolePerId);
}
return object;

Hi @manasaP

Is the issue resolved.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.