Implementing a REST web client