changed POST to PUT, and httplib