general purpose client
improved test client