sunlight api implementation and update to Rep model