שרת Proxy

אם צריך להתחבר ל-Google Ads API דרך שרת proxy, אפשר להגדיר את הנכס proxy בקטע CONNECTION בקובץ google_ads_php.ini:

[CONNECTION]
; Optional proxy settings to be used by requests.
; If you don't have username and password, just specify host and port.
proxy = "protocol://user:pass@host:port"

לדוגמה, אפשר להגדיר את http://user:pass@localhost:8082 בתור שרת proxy. לחלופין, אפשר לקבוע את ההגדרה של שרת ה-proxy באופן פרוגרמטי, בדיוק כמו כל הגדרת תצורה אחרת:

$googleAdsClient = (new GoogleAdsClientBuilder())
    ...
    ->withProxy('protocol://user:pass@host:port')
    ->build();