It can be done using a custom command configured for the User object type. The command will have two built-in actions for adding/removing the user from groups and a PowerShell script to force membership update of rule-based groups. The command will look like the below:
Here is the script for forcing group membership update. In the script, the $groupDNs variable specifies distinguished names (DNs) of the rule-based groups whose membership update should be forced. For information on how to get an object DN, see https://adaxes.com/sdk/HowDoI.GetDnOfObject.
$groupDNs = @("CN=group1,OU=Groups,DC=domain,DC=com", "CN=group2,OU=Groups,DC=domain,DC=com") # TODO: modify me
foreach($dn in $groupDNs)
$group = $Context.BindToObjectByDN($dn)