format httpClient code