backend-client: route requests through HTTP client factory

This commit is contained in:
Michael Bolin
2026-07-09 15:50:15 -07:00
parent 09e074e34e
commit edee7b4a2b
19 changed files with 341 additions and 124 deletions
+5 -3
View File
@@ -18,9 +18,11 @@ async fn rate_limits_check(auth_manager: &AuthManager, config: &Config) -> Optio
return None;
}
let client = BackendClient::from_auth(config.chatgpt_base_url.clone(), &auth)
.map_err(|err| warn!(%err, "failed to construct backend client"))
.ok()?;
let client = BackendClient::from_auth(
config.chatgpt_base_url.clone(),
&auth,
config.http_client_factory(),
);
let snapshots = client
.get_rate_limits_many()