@@ -14,6 +14,7 @@ mod v1;
1414
1515use cidr:: Cidr ;
1616use esc_api:: resources:: MfaStatus ;
17+ use esc_client_base:: build_http_client;
1718
1819use esc_api:: { GroupId , MemberId , OrgId } ;
1920use output:: OutputFormat ;
@@ -1902,7 +1903,7 @@ async fn get_token(
19021903 refresh_token : Option < String > ,
19031904 noninteractive : bool ,
19041905) -> Result < esc_api:: Token , Box < dyn std:: error:: Error > > {
1905- let client = reqwest :: Client :: new ( ) ;
1906+ let client = build_http_client ( ) ;
19061907 match refresh_token {
19071908 Some ( refresh_token) => {
19081909 let otp_prompt: Option < esc_client_base:: identity:: operations:: OtpPrompt > =
@@ -1966,7 +1967,7 @@ impl ClientBuilder {
19661967 authorization_header : token. authorization_header ( ) ,
19671968 } ;
19681969 let sender = esc_api:: RequestSender {
1969- client : reqwest :: Client :: new ( ) ,
1970+ client : build_http_client ( ) ,
19701971 observer : self . observer ,
19711972 } ;
19721973 let client = esc_api:: Client {
@@ -2166,7 +2167,7 @@ async fn call_api<'a, 'b>(
21662167
21672168 AccessCommand :: Tokens ( tokens) => match tokens. tokens_command {
21682169 TokensCommand :: Create ( params) => {
2169- let client = reqwest :: Client :: new ( ) ;
2170+ let client = build_http_client ( ) ;
21702171 let mut store = esc_client_store:: token_store ( token_config) . await ?;
21712172
21722173 match client_builder. noninteractive {
0 commit comments