refactored Couch client to use a provided http client