For line manager certification we want to set up a exclusion rule which will detect underlying IT roles in business role and remove for certification

We are using version 8.2 so getflattenedroles method is not working and I assume it will work for 8.3 version.
I am currently trying with getRequirements, getPermits . Can you suggest some other options to try for 8.2