Native Identity Not populated in account after create account

Hi Everyone,

We have a webservices connector and create account operation. Once the account is created in the target system, the NATIVE IDENTITY will be generated in the target system. We are trying to aggregate native identity using get object (single account aggregation). However, it is not working and single account aggregation is not working.

We wrote an after-operation rule to call http request to get the native identity and update it in processed response object as well. This is not working as well.

Any help/suggestions are much appreciated.

After Rule for create account

*import java.util.HashMap;*
*import java.util.List;*
*import java.util.Map;*
*import java.util.Map.Entry;*
*import java.util.Iterator;*
*import java.util.ArrayList;*
*import java.util.HashMap;*
*import java.util.Map;*
*import connector.common.JsonUtil;*
*import connector.common.Util;*
*import sailpoint.connector.webservices.EndPoint;*
*import sailpoint.connector.webservices.WebServicesClient;*
*import sailpoint.object.Application;*
*import sailpoint.object.ProvisioningPlan;*
*import sailpoint.object.ProvisioningPlan.AccountRequest; *
*import connector.common.JsonUtil;*
*import sailpoint.connector.webservices.WebServicesClient;*
*//We can parse the response(rawResponseObject) to fetch from the respective executed Endpoint operation.*
*Map updatedMapInfo = new HashMap();*
*log.error("Processed response object" + processedResponseObject);*

*if (processedResponseObject != null){*
* *
*    for (Map iterateMap : processedResponseObject) {*
*        if (iterateMap != null ) {*
*            Set keySet = iterateMap.keySet();*
*            for (String s : keySet) {*
*                if (s.equals("id")) {*
*                    Map body = requestEndPoint.getBody();*

*                    String jsonBody = (String) body.get("jsonBody");*
*                    log.info("Rule - Modify Body: running");*
*                    *
*                    *
*                    String role = "";*
*                    String ID = "";*
*                    Map jsonMap = JsonUtil.toMap(jsonBody);*
*                    if (jsonMap != null) {*
*                        Object roleEntry = jsonMap.get("userID");*
*                        if (roleEntry != null) {*
*                            role = (String) roleEntry;*
*                            log.error("responserole: " + role);*
*                        }*
*                    *
*                    }*
*  *
*            //iterateMap.put("id", ID);*
*            WebServicesClient client = new WebServicesClient();*
*            String url = "http://aligne5dev-core.atmosenergy.com:8080/ums/rest/user/userList?status=3&searchBy=User%20ID&searchStr=" + role;*
*            Map args = new HashMap();*
*            args.put(WebServicesClient.ARG_URL, url);*
*            client.configure(args);*
*            Map header = new HashMap();*
*            // Information can be fetched from requestEndpoint and updated in the header and body*
*           // header.put("Authorization","XXXX XXXX");*
*            header.put("Content-Type","application/json");*
*          *
*            List<String> allowedStatuses = new ArrayList();*
*            allowedStatuses.add("2**");*
*            Map payload = new HashMap();*
*        *
*    *
*            String response = client.executeGet(url, header, allowedStatuses);*
*    *
*            // if response contains token it can be updated in the requestEndpoint header or body*
*            // the requestEndpoint will be used for execution of the particular operation configured*
*            log.error("responsealign: " + response);*
*            Map responseMap = JsonUtil.toMap(response);*
*            if (response != null) {*
*                Object IDentry = jsonMap.get("id");*
*                if (IDentry != null) {*
*                    ID = (String) IDentry;*
*                    log.error("responseID: " + ID);*
*                    iterateMap.put("id",ID);*
*                }*

*            }*
*        *
*        }*
*            }*
*        }*
*    }*
*updatedMapInfo.put("data", processedResponseObject);*
*}*

*return updatedMapInfo;*

Hi @ajithkumarreddykallu ,

This may assist you with mentioned issue.

The target source’s nativeIdentity is missing during the create operation using the WSC - Identity Security Cloud (ISC) / ISC Discussion and Questions - SailPoint Developer Community

1 Like

Hi @ajithkumarreddykallu,

The post-operation rule is not necessary if the Get Object operation has been configured. Once the account is created, the Get Object operation retrieves the account information into ISC.

Did you set the native identity as ID in account schmea?
There is an issue with the response mapping for the Create Account operation. Could you kindly share the screenshot of the response mapping?

Regards,
Arun

Thank you. I was missng one / in single account aggregation and it fixed the issue. However, Add entitlement is not working now.

What is the error you are getting?

Did you get any error during add Entitlement operation?

1 Like

Any testing conducted on this endpoint prior to its implementation? If so, please provide the details for debugging.

1 Like

This is postman api.

NO ERROR. Just entitlement bot getting added during create account. But if I request for another entitlement, it is getting added.

Thank you so much for your help

1 Like

Hi

Have you try with $getObject.nativeIdentity$?

Thanks,
Siva.K

Did you set an entitlement schema?

you have “$plan.nativeIdentity$” in quotes in IdentityNow, but in Postman, there are no quotes. Try removing the quotes in your call.

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