made api call from rails