Add POST and PUT methods to client.js