add http client function