fix: 用http.client替代httpx认证,绕过CF指纹拦截
- 认证请求改用stdlib http.client,避免httpx TLS指纹被Cloudflare拦截 - login_as为空时不传x-login-as header - 服务器直连api.airwallex.com已验证201成功
This commit is contained in:
@@ -44,7 +44,7 @@ def get_client(db: Session) -> ProxiedAirwallexClient:
|
||||
client_id = _get_setting(db, "airwallex_client_id")
|
||||
api_key = _get_setting(db, "airwallex_api_key")
|
||||
base_url = _get_setting(db, "airwallex_base_url", "https://api-demo.airwallex.com/")
|
||||
login_as = _get_setting(db, "airwallex_login_as")
|
||||
login_as = _get_setting(db, "airwallex_login_as").strip() or None
|
||||
proxy_url = _build_proxy_url(db)
|
||||
|
||||
if not client_id or not api_key:
|
||||
|
||||
Reference in New Issue
Block a user