Cleanse function is the apt approach, Are you using SA based IDD application generated BES or it is Complete BE based E360 Application?
I used IDD to get entities in Provisioning. But customer wants to have a customized error message in E360 UI when duplicate record is found. So I thought that BES external call or CS step or WSDL based services would help on this. But don't know how to do? I don't see a complete example even in resource kit too. Everything is half baked.
Please refer any article to refer and try the right one.
Are you able to achieve using External calls?