Initial commit for new schedules api and queries