Added build_client method