interact with api rails