implemented client + added API methods