DEFAULT_USER_AGENT
DEFAULT_USER_AGENT
Builds AdWords sessions.
fromFile(string $path = null): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Reads configuration settings from the specified filepath. The filepath is optional, and if omitted, it will look for the default configuration filename in the home directory of the user running PHP.
string | $path | the filepath |
if the configuration file could not be found
this builder populated from the configuration
from(\Google\AdsApi\Common\Configuration $configuration): \Google\AdsApi\Common\AdsBuilder
Populates this builder from the specified configuration object.
\Google\AdsApi\Common\Configuration | $configuration | the configuration |
this builder populated from the configuration
withDeveloperToken(string $developerToken): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes a developer token. This is required.
string | $developerToken |
this builder
withUserAgent(string $userAgent): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes user agent. This is required.
string | $userAgent |
this builder
withEndpoint(string|null $endpoint): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes the AdWords API server's base endpoint. This is optional.
string|null | $endpoint |
this builder
withOAuth2Credential(\Google\Auth\FetchAuthTokenInterface $oAuth2Credential): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes the OAuth2 credential to be used for authentication. This is required.
\Google\Auth\FetchAuthTokenInterface | $oAuth2Credential |
this builder
withConnectionSettings(\Google\AdsApi\Common\ConnectionSettings|null $connectionSettings): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes connection settings. This is optional.
\Google\AdsApi\Common\ConnectionSettings|null | $connectionSettings |
this builder
withSoapSettings(\Google\AdsApi\Common\SoapSettings|null $soapSettings): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes SOAP settings. This is optional.
\Google\AdsApi\Common\SoapSettings|null | $soapSettings |
this builder
withClientCustomerId(string|null $clientCustomerId): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes a client customer ID. This is required except when using CustomerService.
string|null | $clientCustomerId |
this builder
enableValidateOnly(): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Enables validate only. Disabled by default.
this builder
enablePartialFailure(): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Enables partial failure. Disabled by default.
this builder
disableIncludeUtilitiesInUserAgent(): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Disables include utilities in user agent option. Enabled by default.
this builder
withAdsHeaderFormatter(\Google\AdsApi\Common\AdsHeaderFormatter|null $adsHeaderFormatter): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes ads header formatter. This is optional.
\Google\AdsApi\Common\AdsHeaderFormatter|null | $adsHeaderFormatter |
this builder
withReportSettings(\Google\AdsApi\AdWords\ReportSettings|null $reportSettings): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes report settings. This is optional.
\Google\AdsApi\AdWords\ReportSettings|null | $reportSettings |
this builder
withSoapLogger(\Psr\Log\LoggerInterface|null $soapLogger): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes a PSR-3 compliant logger for logging SOAP calls. This is optional.
\Psr\Log\LoggerInterface|null | $soapLogger |
this builder
withReportDownloaderLogger(\Psr\Log\LoggerInterface|null $reportDownloaderLogger): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes a PSR-3 compliant logger for the report downloader utility to log report download calls. This is optional.
\Psr\Log\LoggerInterface|null | $reportDownloaderLogger |
this builder
withBatchJobsUtilLogger(\Psr\Log\LoggerInterface|null $batchJobsUtilLogger): \Google\AdsApi\AdWords\AdWordsSessionBuilder
Includes a PSR-3 compliant logger for the batch jobs utility to log batch job upload and download calls. This is optional.
\Psr\Log\LoggerInterface|null | $batchJobsUtilLogger |
this builder
getConnectionSettings(): \Google\AdsApi\Common\ConnectionSettings
Gets the connection settings.
getSoapSettings(): \Google\AdsApi\Common\SoapSettings
Gets the SOAP settings.
getAdsHeaderFormatter(): \Google\AdsApi\Common\AdsHeaderFormatter
Gets ads header formatter.
getReportSettings(): \Google\AdsApi\AdWords\ReportSettings
Gets the report settings.