Using idn.getFirstAccount() in Identity Attribute Rule

Hi @mingsiewang

Of course getFirstAccount method works for all the connector sources. Check if some issue is there with the identity you are testing, maybe it is a data issue.

There is lack of clarity in using sourceName in getting account whether to use [source] appended, for example if your source name is HR then in

Account acct = idn.getFirstAccount("HR [source]", identity.getName());

Last thing I would like to inform you is, you don’t need to depend on Rule for this requirement. I know Rule is more flexible in writing complex logics compared to Transform, but you need to depend on SailPoint Expert Services for any change or if you would like to know what is happening.

Due to that, we avoid developing cloud Rules unless there is no other way. You can develop a static transform and get the account details, check this post.
Display multiple account id using transform - Identity Security Cloud (ISC) / ISC Discussion and Questions - SailPoint Developer Community

Thanks
Krish