Fix rails controllers for json responses
Add connections