refactor client config