major cleanup API