rails api for eudaimonia front-end