CLIENTJAVA-5 refactor existing client library to be compatible with new client api endpoints, example code written for basic querying