Hi Caetano,
You are right. In my comment I am supposing that they know which are the versions to be deleted. Now if what they want is a transaction to identify those inactive versions and then proceed with the deletion, a custom program will be only possible alternative.
Kind Regards,
Mariano