Ads API .NET library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Google.Api.Ads.AdWords.Lib.AdWordsAppConfig Class Reference

This class reads the configuration keys from App.config. More...

Inheritance diagram for Google.Api.Ads.AdWords.Lib.AdWordsAppConfig:
Google.Api.Ads.Common.Lib.AppConfigBase Google.Api.Ads.Common.Lib.AppConfig

Public Member Functions

override string GetUserAgent ()
 Gets a useragent string that can be used with the library. More...
 
override string GetDefaultOAuth2Scope ()
 Gets the default OAuth2 scope. More...
 
 AdWordsAppConfig ()
 Public constructor. Loads the configuration from the More...
 
 AdWordsAppConfig (IConfigurationRoot configurationRoot)
 Public constructor. Loads the configuration from an IConfigurationRoot. More...
 
 AdWordsAppConfig (IConfigurationSection configurationSection)
 Public constructor. Loads the configuration from a IConfigurationSection. More...
 
- Public Member Functions inherited from Google.Api.Ads.Common.Lib.AppConfigBase
 AppConfigBase ()
 The default constructor. More...
 
 AppConfigBase (IConfigurationRoot configurationRoot)
 Initializes a new instance of the AppConfigBase class. More...
 
 AppConfigBase (IConfigurationSection configurationSection)
 Initializes a new instance of the AppConfigBase class. More...
 
virtual object Clone ()
 Creates a new object that is a copy of the current instance. More...
 

Protected Member Functions

override void ReadSettings (Dictionary< string, string > settings)
 Read all settings from App.config. More...
 
- Protected Member Functions inherited from Google.Api.Ads.Common.Lib.AppConfigBase
void LoadFromConfiguration (IConfiguration configuration, string sectionName)
 Initializes a new instance of the AppConfigBase class. More...
 
void LoadFromAppConfigSection (string sectionName)
 Attempts to load the configuration section with the given name. More...
 
void ReadSetting (Dictionary< string, string > settings, ConfigSetting settingField)
 Reads a setting from a given dictionary. More...
 
void SetPropertyAndNotify< T > (ConfigSetting< T > field, T newValue, [CallerMemberName] String propertyName="")
 Sets the specified property and notify any listeners. More...
 

Properties

string ClientCustomerId [get, set]
 Gets or sets the client customerId to be used in SOAP headers. More...
 
string DeveloperToken [get, set]
 Gets or sets the developer token to be used in SOAP headers. More...
 
long MerchantCenterId [get, set]
 Gets or sets the Merchant Center ID to be used with Shopping campaigns. More...
 
string GMBLoginEmail [get, set]
 Gets or sets the Google My Business (GMB) OAuth2 login email. More...
 
string GMBOAuth2RefreshToken [get, set]
 Gets or sets the Google My Business (GMB) OAuth2 refresh token. More...
 
bool SkipReportHeader [get, set]
 Gets or sets whether reporting headers should be skipped. More...
 
bool SkipReportSummary [get, set]
 Gets or sets whether report summary should be skipped. More...
 
bool SkipColumnHeader [get, set]
 Gets or sets whether report column header should be skipped. More...
 
bool IncludeZeroImpressions [get, set]
 Gets or sets whether zero impression rows should be skipped. More...
 
bool UseRawEnumValues [get, set]
 Gets or sets whether enum values should be returned as actual enum values or display values. More...
 
string UserAgent [get, set]
 Gets or sets the useragent to be used in SOAP headers. More...
 
string AdWordsApiServer [get, set]
 Gets or sets the URL for AdWords API. More...
 
AdWordsAuthorizationMethod AuthorizationMethod [get, set]
 Gets or sets the authorization method. More...
 
- Properties inherited from Google.Api.Ads.Common.Lib.AppConfigBase
bool MaskCredentials [get, set]
 Gets or sets whether the credentials in the log file should be masked. More...
 
IWebProxy Proxy [get, set]
 Gets or sets the web proxy to be used with the services. More...
 
int Timeout [get, set]
 Gets or sets the timeout for Ads services in milliseconds. More...
 
int RetryCount [get, set]
 Gets or sets the number of times to retry a call if an API call fails and can be retried. More...
 
bool EnableGzipCompression [get, set]
 Gets or sets whether gzip compression should be turned on for SOAP requests and responses. More...
 
string OAuth2ServerUrl [get, set]
 Gets or sets the OAuth2 server URL. More...
 
string OAuth2ClientId [get, set]
 Gets or sets the OAuth2 client ID. More...
 
string OAuth2ClientSecret [get, set]
 Gets or sets the OAuth2 client secret. More...
 
string OAuth2AccessToken [get, set]
 Gets or sets the OAuth2 access token. More...
 
string OAuth2RefreshToken [get, set]
 Gets or sets the OAuth2 refresh token. More...
 
string OAuth2Scope [get, set]
 Gets or sets the OAuth2 scope. More...
 
string OAuth2RedirectUri [get, set]
 Gets or sets the OAuth2 redirect URI. More...
 
OAuth2Flow OAuth2Mode [get, set]
 Gets or sets the OAuth2 mode. More...
 
string OAuth2PrnEmail [get, set]
 Gets or sets the OAuth2 prn email. More...
 
string OAuth2ServiceAccountEmail [get, set]
 Gets the OAuth2 service account email. More...
 
string OAuth2PrivateKey [get, set]
 Gets the OAuth2 private key for service account flow. More...
 
string OAuth2SecretsJsonPath [get, set]
 Gets or sets the OAuth2 secrets JSON file path. More...
 
bool IncludeUtilitiesInUserAgent [get, set]
 Gets or sets whether usage of various client library features should be tracked. More...
 
string Signature [get]
 Gets the signature for this library. More...
 
virtual long UnixTimestamp [get]
 Gets the number of seconds after Jan 1, 1970, 00:00:00 More...
 
- Properties inherited from Google.Api.Ads.Common.Lib.AppConfig
bool MaskCredentials [get]
 Gets whether the credentials in the log file should be masked. More...
 
string OAuth2ServerUrl [get, set]
 Gets or sets the OAuth2 server URL. More...
 
OAuth2Flow OAuth2Mode [get, set]
 Gets or sets the OAuth2 mode. More...
 
string OAuth2AccessToken [get, set]
 Gets or sets the OAuth2 access token. More...
 
string OAuth2ClientId [get, set]
 Gets or sets the OAuth2 client id. More...
 
string OAuth2ClientSecret [get, set]
 Gets or sets the OAuth2 client secret. More...
 
string OAuth2RedirectUri [get, set]
 Gets or sets the OAuth2 redirect URI. More...
 
string OAuth2RefreshToken [get, set]
 OAuth2 refresh token. More...
 
string OAuth2Scope [get, set]
 Gets or sets the OAuth2 scope. More...
 
string OAuth2PrnEmail [get, set]
 Gets or sets the OAuth2 prn email. More...
 
string OAuth2SecretsJsonPath [get, set]
 Gets or sets the OAuth2 secrets JSON file. More...
 
string OAuth2PrivateKey [get]
 Gets the OAuth2 private key for service account flow. More...
 
string OAuth2ServiceAccountEmail [get]
 Gets the OAuth2 service account email. More...
 
bool IncludeUtilitiesInUserAgent [get, set]
 Gets or sets whether usage information of various client library features should be included in the user agent. More...
 
IWebProxy Proxy [get, set]
 Gets the web proxy to be used with the services. More...
 
int RetryCount [get, set]
 Gets or sets the number of times to retry a call if an API call fails and can be retried. More...
 
string Signature [get]
 Gets the signature for this library. More...
 
int Timeout [get, set]
 Gets or sets the timeout for Ads services in milliseconds. More...
 
bool EnableGzipCompression [get, set]
 Gets or sets whether gzip compression should be turned on for SOAP requests and responses. More...
 
long UnixTimestamp [get]
 Gets the number of seconds after Jan 1, 1970, 00:00:00 More...
 

Additional Inherited Members

- Events inherited from Google.Api.Ads.Common.Lib.AppConfigBase
PropertyChangedEventHandler PropertyChanged
 Occurs when a property value changes. More...
 
- Events inherited from Google.Api.Ads.Common.Lib.AppConfig
PropertyChangedEventHandler PropertyChanged
 Occurs when a property is changed. More...
 

Detailed Description

This class reads the configuration keys from App.config.

Constructor & Destructor Documentation

Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.AdWordsAppConfig ( )
inline

Public constructor. Loads the configuration from the

AdWordsApi section of the App.config / Web.config.

Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.AdWordsAppConfig ( IConfigurationRoot  configurationRoot)
inline

Public constructor. Loads the configuration from an IConfigurationRoot.

Parameters
configurationRootThe configuration root.
Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.AdWordsAppConfig ( IConfigurationSection  configurationSection)
inline

Public constructor. Loads the configuration from a IConfigurationSection.

Parameters
configurationSectionThe configuration section.

Member Function Documentation

override string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.GetDefaultOAuth2Scope ( )
inlinevirtual

Gets the default OAuth2 scope.

Reimplemented from Google.Api.Ads.Common.Lib.AppConfigBase.

override string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.GetUserAgent ( )
inlinevirtual

Gets a useragent string that can be used with the library.

Reimplemented from Google.Api.Ads.Common.Lib.AppConfigBase.

override void Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.ReadSettings ( Dictionary< string, string >  settings)
inlineprotectedvirtual

Read all settings from App.config.

Parameters
settingsThe parsed App.config settings.

Reimplemented from Google.Api.Ads.Common.Lib.AppConfigBase.

Property Documentation

string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.AdWordsApiServer
getset

Gets or sets the URL for AdWords API.

Referenced by Google.Api.Ads.AdWords.Lib.AdWordsServiceFactory.CreateService().

AdWordsAuthorizationMethod Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.AuthorizationMethod
getset

Gets or sets the authorization method.

This setting is only for testing purposes.

string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.ClientCustomerId
getset

Gets or sets the client customerId to be used in SOAP headers.

Referenced by Google.Api.Ads.AdWords.Lib.AdWordsServiceFactory.ReadHeadersFromConfig().

string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.DeveloperToken
getset

Gets or sets the developer token to be used in SOAP headers.

string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.GMBLoginEmail
getset

Gets or sets the Google My Business (GMB) OAuth2 login email.

This property is used only for testing purposes.

string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.GMBOAuth2RefreshToken
getset

Gets or sets the Google My Business (GMB) OAuth2 refresh token.

This property is used only for testing purposes.

bool Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.IncludeZeroImpressions
getset

Gets or sets whether zero impression rows should be skipped.

This setting is a three-valued logic. If this field is set to true or false, the client library sends the value to the server, and the server responds by including or excluding the zero impression rows. If this value is set to null (either explicitly in the code, or by commenting out the key in App.config / Web.config), then this value is not sent to the server, and the server behaves as explained on https://developers.google.com/adwords/api/docs/guides/zero-impression-reports#default_behavior.

Referenced by Google.Api.Ads.AdWords.Examples.CSharp.OAuth.Default.OnDownloadReportButtonClick().

long Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.MerchantCenterId
getset

Gets or sets the Merchant Center ID to be used with Shopping campaigns.

bool Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.SkipColumnHeader
getset

Gets or sets whether report column header should be skipped.

bool Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.SkipReportHeader
getset

Gets or sets whether reporting headers should be skipped.

bool Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.SkipReportSummary
getset

Gets or sets whether report summary should be skipped.

string Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.UserAgent
getset

Gets or sets the useragent to be used in SOAP headers.

bool Google.Api.Ads.AdWords.Lib.AdWordsAppConfig.UseRawEnumValues
getset

Gets or sets whether enum values should be returned as actual enum values or display values.

This setting is a three-valued logic. If this field is set to true or false, the client library sends the value to the server, and the server responds by returning the actual enum values or the display values. If this value is set to null (either explicitly in the code, or by commenting out the key in App.config / Web.config), then this value is not sent to the server, and the server behaves as explained on https://developers.google.com/adwords/api/docs/guides/reporting#request-headers.


The documentation for this class was generated from the following file: