overhaul api cleanups