change api and app models to have start and end times