Wenn Sie über einen Proxy eine Verbindung zur Google Ads API herstellen müssen, legen Sie in der Datei google_ads_php.ini
im Abschnitt CONNECTION
das Attribut proxy
fest:
[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"
Beispielsweise können Sie http://user:pass@localhost:8082
als Proxy angeben.
Alternativ können Sie die Proxy-Einstellung wie jede andere Konfigurationseinstellung programmatisch konfigurieren:
$googleAdsClient = (new GoogleAdsClientBuilder())
...
->withProxy('protocol://user:pass@host:port')
->build();