simplified http request logic with newer httpclient