Thursday, April 22, 2021

Rule - Adding Identity to WorkGroup

 import sailpoint.object.QueryOptions;
import sailpoint.object.Filter;
import sailpoint.object.Identity;
  //get the workgroup
  Identity workGroupName = context.getObjectByName(Identity.class,"DemoWorkGroup");
  // get the identity
  Identity identityName = context.getObjectByName(Identity.class,"Aaron.Nichols");
  if(workGroupName!=null && identityName!=null ){
  identityName.add(workGroupName);
  context.saveObject(identityName);
  context.commitTransaction();
  }

Comment below if you find this post helpful.

No comments:

Post a Comment

Form AllowedValues rule to filter Identities with Active Regular Active Directory accounts and identity is active and correlated

 The rule type is AllowedValues. import org.apache.log4j.Level ; import org.apache.log4j.Logger ; import sailpoint.object.Filter ; import sa...