improve http-client's api