ServiceNow Catalog Integration - Comments Required

It appears the ServiceNow Catalog Integration does not require comments on access request when an access profile has been marked as “comments required” in IdentityNow. Has anyone been able to require comments on requests that require comments on the SailPoint side of provisioning?

1 Like

The comments on the Access Request get mapped to the Description field in Service Now during ticket creation. I haven’t tried this, but i think if you want comments to be mandatory, you may have to mark description as mandatory on Service Now side as “comments required” seems to be applicable to Sailpoint side only.

https://documentation.sailpoint.com/connectors/servicenow/sdim/help/integrating_servicenow_sdim/managing_comments_access_request.html

1 Like

Thanks for your reply. Ill try this, but I dont think it will solve the problem. Tracing the widget code, I can see where there is logic in place to add default comments when a user does not enter any, so comments would never actually be null.

1 Like

This worked for me:

  1. In the Controller javascript, modify any code that will put a default comment in the access list requests like this: accessListTemp9[k9].comments = "Some placeholder" to this accessListTemp9[k9].comments = '';
  2. In the Server Script, in the validateRequest method, in the else block where there is no RemoveData, add this after the existing line that starts with errors = idn_validateAccess...:
//CS - Adding validation requiring comments
                    var accessList = requestData[index1].accessList;
                    var hasEmptyComment = false;
                    if (accessList) {
                        for (var i = 0; i < accessList.length; i++) {
                            if (accessList[i].comments === '') {
                                hasEmptyComment = true;
                                break;
                            }
                        }
                    }
                    if (hasEmptyComment) {
                        errors.push('A comment is required to move forward.');
                    }
1 Like

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