remove rest-client, require json and render reterned hashes into json