refactored the various apis out of the app runner