partition
stringclasses
3 values
func_name
stringlengths
1
134
docstring
stringlengths
1
46.9k
path
stringlengths
4
223
original_string
stringlengths
75
104k
code
stringlengths
75
104k
docstring_tokens
listlengths
1
1.97k
repo
stringlengths
7
55
language
stringclasses
1 value
url
stringlengths
87
315
code_tokens
listlengths
19
28.4k
sha
stringlengths
40
40
train
AddMonths
A simple convenience utility for adding months to a given start date. This increments the months by adding the number of days in the current month to the current month, for each month. Args: start_date: date The date months are being added to. months: int The number of months to add. Returns: A d...
examples/adwords/v201809/remarketing/add_rule_based_user_lists.py
def AddMonths(start_date, months): """A simple convenience utility for adding months to a given start date. This increments the months by adding the number of days in the current month to the current month, for each month. Args: start_date: date The date months are being added to. months: int The numb...
def AddMonths(start_date, months): """A simple convenience utility for adding months to a given start date. This increments the months by adding the number of days in the current month to the current month, for each month. Args: start_date: date The date months are being added to. months: int The numb...
[ "A", "simple", "convenience", "utility", "for", "adding", "months", "to", "a", "given", "start", "date", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/remarketing/add_rule_based_user_lists.py#L209-L228
[ "def", "AddMonths", "(", "start_date", ",", "months", ")", ":", "current_date", "=", "start_date", "i", "=", "0", "while", "i", "<", "months", ":", "month_days", "=", "calendar", ".", "monthrange", "(", "current_date", ".", "year", ",", "current_date", "."...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DisplayEstimate
Displays mean average cpc, position, clicks, and total cost for estimate. Args: message: str message to display for the given estimate. min_estimate: sudsobject containing a minimum estimate from the TrafficEstimatorService response. max_estimate: sudsobject containing a maximum estimate from the ...
examples/adwords/v201809/optimization/estimate_keyword_traffic.py
def DisplayEstimate(message, min_estimate, max_estimate): """Displays mean average cpc, position, clicks, and total cost for estimate. Args: message: str message to display for the given estimate. min_estimate: sudsobject containing a minimum estimate from the TrafficEstimatorService response. ma...
def DisplayEstimate(message, min_estimate, max_estimate): """Displays mean average cpc, position, clicks, and total cost for estimate. Args: message: str message to display for the given estimate. min_estimate: sudsobject containing a minimum estimate from the TrafficEstimatorService response. ma...
[ "Displays", "mean", "average", "cpc", "position", "clicks", "and", "total", "cost", "for", "estimate", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/optimization/estimate_keyword_traffic.py#L147-L175
[ "def", "DisplayEstimate", "(", "message", ",", "min_estimate", ",", "max_estimate", ")", ":", "# Find the mean of the min and max values.", "mean_avg_cpc", "=", "(", "_CalculateMean", "(", "min_estimate", "[", "'averageCpc'", "]", "[", "'microAmount'", "]", ",", "max_...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ClientConfigBuilder.Build
Builds a client config dictionary used in the OAuth 2.0 flow.
examples/adwords/authentication/generate_refresh_token.py
def Build(self): """Builds a client config dictionary used in the OAuth 2.0 flow.""" if all((self.client_type, self.client_id, self.client_secret, self.auth_uri, self.token_uri)): client_config = { self.client_type: { 'client_id': self.client_id, 'client_s...
def Build(self): """Builds a client config dictionary used in the OAuth 2.0 flow.""" if all((self.client_type, self.client_id, self.client_secret, self.auth_uri, self.token_uri)): client_config = { self.client_type: { 'client_id': self.client_id, 'client_s...
[ "Builds", "a", "client", "config", "dictionary", "used", "in", "the", "OAuth", "2", ".", "0", "flow", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/authentication/generate_refresh_token.py#L65-L80
[ "def", "Build", "(", "self", ")", ":", "if", "all", "(", "(", "self", ".", "client_type", ",", "self", ".", "client_id", ",", "self", ".", "client_secret", ",", "self", ".", "auth_uri", ",", "self", ".", "token_uri", ")", ")", ":", "client_config", "...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
FormatSOAPDateTime
Format a SOAP DateTime object for printing. Args: value: The DateTime object to format. Returns: A string representing the value.
examples/ad_manager/v201811/forecast_service/get_availability_forecast.py
def FormatSOAPDateTime(value): """Format a SOAP DateTime object for printing. Args: value: The DateTime object to format. Returns: A string representing the value. """ value_date = value['date'] return '%s-%s-%s %s:%s:%s (%s)' % ( value_date['year'], value_date['month'], value_date['day'], ...
def FormatSOAPDateTime(value): """Format a SOAP DateTime object for printing. Args: value: The DateTime object to format. Returns: A string representing the value. """ value_date = value['date'] return '%s-%s-%s %s:%s:%s (%s)' % ( value_date['year'], value_date['month'], value_date['day'], ...
[ "Format", "a", "SOAP", "DateTime", "object", "for", "printing", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/ad_manager/v201811/forecast_service/get_availability_forecast.py#L206-L218
[ "def", "FormatSOAPDateTime", "(", "value", ")", ":", "value_date", "=", "value", "[", "'date'", "]", "return", "'%s-%s-%s %s:%s:%s (%s)'", "%", "(", "value_date", "[", "'year'", "]", ",", "value_date", "[", "'month'", "]", ",", "value_date", "[", "'day'", "]...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CalculateForecastStats
Calculate forecast percentage stats. Args: matched: The number of matched impressions. available: The number of available impressions. possible: The optional number of possible impressions. Returns: The percentage of impressions that are available and possible.
examples/ad_manager/v201811/forecast_service/get_availability_forecast.py
def CalculateForecastStats(matched, available, possible=None): """Calculate forecast percentage stats. Args: matched: The number of matched impressions. available: The number of available impressions. possible: The optional number of possible impressions. Returns: The percentage of impressions t...
def CalculateForecastStats(matched, available, possible=None): """Calculate forecast percentage stats. Args: matched: The number of matched impressions. available: The number of available impressions. possible: The optional number of possible impressions. Returns: The percentage of impressions t...
[ "Calculate", "forecast", "percentage", "stats", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/ad_manager/v201811/forecast_service/get_availability_forecast.py#L221-L245
[ "def", "CalculateForecastStats", "(", "matched", ",", "available", ",", "possible", "=", "None", ")", ":", "if", "matched", ">", "0", ":", "available_percent", "=", "(", "float", "(", "available", ")", "/", "matched", ")", "*", "100.", "else", ":", "avai...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CreateShoppingCampaign
Creates a shopping campaign with the given budget and merchant IDs. Args: client: an AdWordsClient instance. budget_id: the str ID of the budget to be associated with the shopping campaign. merchant_id: the str ID of the merchant account to be associated with the shopping campaign. Returns...
examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py
def CreateShoppingCampaign(client, budget_id, merchant_id): """Creates a shopping campaign with the given budget and merchant IDs. Args: client: an AdWordsClient instance. budget_id: the str ID of the budget to be associated with the shopping campaign. merchant_id: the str ID of the merchant acco...
def CreateShoppingCampaign(client, budget_id, merchant_id): """Creates a shopping campaign with the given budget and merchant IDs. Args: client: an AdWordsClient instance. budget_id: the str ID of the budget to be associated with the shopping campaign. merchant_id: the str ID of the merchant acco...
[ "Creates", "a", "shopping", "campaign", "with", "the", "given", "budget", "and", "merchant", "IDs", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py#L182-L234
[ "def", "CreateShoppingCampaign", "(", "client", ",", "budget_id", ",", "merchant_id", ")", ":", "campaign_service", "=", "client", ".", "GetService", "(", "'CampaignService'", ",", "'v201809'", ")", "campaign", "=", "{", "'name'", ":", "'Shopping campaign #%s'", "...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CreateAdGroup
Creates an AdGroup for the given shopping campaign ID. Args: client: an AdWordsClient instance. campaign_id: the str ID of a shopping campaign. Returns: The created AdGroup as a sudsobject.
examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py
def CreateAdGroup(client, campaign_id): """Creates an AdGroup for the given shopping campaign ID. Args: client: an AdWordsClient instance. campaign_id: the str ID of a shopping campaign. Returns: The created AdGroup as a sudsobject. """ ad_group_service = client.GetService('AdGroupService', 'v20...
def CreateAdGroup(client, campaign_id): """Creates an AdGroup for the given shopping campaign ID. Args: client: an AdWordsClient instance. campaign_id: the str ID of a shopping campaign. Returns: The created AdGroup as a sudsobject. """ ad_group_service = client.GetService('AdGroupService', 'v20...
[ "Creates", "an", "AdGroup", "for", "the", "given", "shopping", "campaign", "ID", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py#L237-L279
[ "def", "CreateAdGroup", "(", "client", ",", "campaign_id", ")", ":", "ad_group_service", "=", "client", ".", "GetService", "(", "'AdGroupService'", ",", "'v201809'", ")", "adgroup", "=", "{", "# Required: Set the ad group type to SHOPPING_SHOWCASE_ADS", "'adGroupType'", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CreateShowcaseAd
Creates a showcase add for the given AdGroup with the given images. Args: client: an AdWordsClient instance. adgroup: a dict or suds object defining an AdGroup for a Shopping Campaign. expanded_image_filepath: a str filepath to a .jpg file that will be used as the Showcase Ad's expandedImage. c...
examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py
def CreateShowcaseAd(client, adgroup, expanded_image_filepath, collapsed_image_filepath): """Creates a showcase add for the given AdGroup with the given images. Args: client: an AdWordsClient instance. adgroup: a dict or suds object defining an AdGroup for a Shopping Campaign. expa...
def CreateShowcaseAd(client, adgroup, expanded_image_filepath, collapsed_image_filepath): """Creates a showcase add for the given AdGroup with the given images. Args: client: an AdWordsClient instance. adgroup: a dict or suds object defining an AdGroup for a Shopping Campaign. expa...
[ "Creates", "a", "showcase", "add", "for", "the", "given", "AdGroup", "with", "the", "given", "images", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py#L282-L330
[ "def", "CreateShowcaseAd", "(", "client", ",", "adgroup", ",", "expanded_image_filepath", ",", "collapsed_image_filepath", ")", ":", "ad_group_ad_service", "=", "client", ".", "GetService", "(", "'AdGroupAdService'", ",", "'v201809'", ")", "showcase_ad", "=", "{", "...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
UploadImage
Uploads a .jpg image with the given filepath via the AdWords MediaService. Args: client: an AdWordsClient instance. filepath: a str filepath to the .jpg file to be uploaded. Returns: The created Image as a sudsobject.
examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py
def UploadImage(client, filepath): """Uploads a .jpg image with the given filepath via the AdWords MediaService. Args: client: an AdWordsClient instance. filepath: a str filepath to the .jpg file to be uploaded. Returns: The created Image as a sudsobject. """ media_service = client.GetService('M...
def UploadImage(client, filepath): """Uploads a .jpg image with the given filepath via the AdWords MediaService. Args: client: an AdWordsClient instance. filepath: a str filepath to the .jpg file to be uploaded. Returns: The created Image as a sudsobject. """ media_service = client.GetService('M...
[ "Uploads", "a", ".", "jpg", "image", "with", "the", "given", "filepath", "via", "the", "AdWords", "MediaService", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py#L333-L356
[ "def", "UploadImage", "(", "client", ",", "filepath", ")", ":", "media_service", "=", "client", ".", "GetService", "(", "'MediaService'", ",", "'v201809'", ")", "with", "open", "(", "filepath", ",", "'rb'", ")", "as", "image_handle", ":", "image_data", "=", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CreateProductPartition
Creates a ProductPartition tree for the given AdGroup ID. Args: client: an AdWordsClient instance. adgroup_id: a str AdGroup ID. Returns: The ProductPartition tree as a sudsobject.
examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py
def CreateProductPartition(client, adgroup_id): """Creates a ProductPartition tree for the given AdGroup ID. Args: client: an AdWordsClient instance. adgroup_id: a str AdGroup ID. Returns: The ProductPartition tree as a sudsobject. """ ad_group_criterion_service = client.GetService('AdGroupCrite...
def CreateProductPartition(client, adgroup_id): """Creates a ProductPartition tree for the given AdGroup ID. Args: client: an AdWordsClient instance. adgroup_id: a str AdGroup ID. Returns: The ProductPartition tree as a sudsobject. """ ad_group_criterion_service = client.GetService('AdGroupCrite...
[ "Creates", "a", "ProductPartition", "tree", "for", "the", "given", "AdGroup", "ID", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py#L359-L393
[ "def", "CreateProductPartition", "(", "client", ",", "adgroup_id", ")", ":", "ad_group_criterion_service", "=", "client", ".", "GetService", "(", "'AdGroupCriterionService'", ",", "'v201809'", ")", "helper", "=", "ProductPartitionHelper", "(", "adgroup_id", ")", "root...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ProductPartitionHelper.CreateSubdivision
Creates a subdivision node. Args: parent: The node that should be this node's parent. value: The value being partitioned on. Returns: A new subdivision node.
examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py
def CreateSubdivision(self, parent=None, value=None): """Creates a subdivision node. Args: parent: The node that should be this node's parent. value: The value being partitioned on. Returns: A new subdivision node. """ division = { 'xsi_type': 'ProductPartition', '...
def CreateSubdivision(self, parent=None, value=None): """Creates a subdivision node. Args: parent: The node that should be this node's parent. value: The value being partitioned on. Returns: A new subdivision node. """ division = { 'xsi_type': 'ProductPartition', '...
[ "Creates", "a", "subdivision", "node", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py#L60-L89
[ "def", "CreateSubdivision", "(", "self", ",", "parent", "=", "None", ",", "value", "=", "None", ")", ":", "division", "=", "{", "'xsi_type'", ":", "'ProductPartition'", ",", "'partitionType'", ":", "'SUBDIVISION'", ",", "'id'", ":", "str", "(", "self", "."...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ProductPartitionHelper.CreateUnit
Creates a unit node. Args: parent: The node that should be this node's parent. value: The value being partitioned on. bid_amount: The amount to bid for matching products, in micros. Returns: A new unit node.
examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py
def CreateUnit(self, parent=None, value=None, bid_amount=None): """Creates a unit node. Args: parent: The node that should be this node's parent. value: The value being partitioned on. bid_amount: The amount to bid for matching products, in micros. Returns: A new unit node. """ ...
def CreateUnit(self, parent=None, value=None, bid_amount=None): """Creates a unit node. Args: parent: The node that should be this node's parent. value: The value being partitioned on. bid_amount: The amount to bid for matching products, in micros. Returns: A new unit node. """ ...
[ "Creates", "a", "unit", "node", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_shopping_campaign_for_showcase_ads.py#L91-L138
[ "def", "CreateUnit", "(", "self", ",", "parent", "=", "None", ",", "value", "=", "None", ",", "bid_amount", "=", "None", ")", ":", "unit", "=", "{", "'xsi_type'", ":", "'ProductPartition'", ",", "'partitionType'", ":", "'UNIT'", "}", "# The root node has nei...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
main
Retrieve and display the access and refresh token.
examples/ad_manager/authentication/generate_refresh_token.py
def main(client_id, client_secret, scopes): """Retrieve and display the access and refresh token.""" client_config = ClientConfigBuilder( client_type=ClientConfigBuilder.CLIENT_TYPE_WEB, client_id=client_id, client_secret=client_secret) flow = InstalledAppFlow.from_client_config( client_config....
def main(client_id, client_secret, scopes): """Retrieve and display the access and refresh token.""" client_config = ClientConfigBuilder( client_type=ClientConfigBuilder.CLIENT_TYPE_WEB, client_id=client_id, client_secret=client_secret) flow = InstalledAppFlow.from_client_config( client_config....
[ "Retrieve", "and", "display", "the", "access", "and", "refresh", "token", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/ad_manager/authentication/generate_refresh_token.py#L83-L110
[ "def", "main", "(", "client_id", ",", "client_secret", ",", "scopes", ")", ":", "client_config", "=", "ClientConfigBuilder", "(", "client_type", "=", "ClientConfigBuilder", ".", "CLIENT_TYPE_WEB", ",", "client_id", "=", "client_id", ",", "client_secret", "=", "cli...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ShowAdGroups.post
Handle post request.
examples/adwords/adwords_appengine_demo/views/show_adgroups_view.py
def post(self): """Handle post request.""" client_customer_id = self.request.get('clientCustomerId') campaign_id = self.request.get('campaignId') if not client_customer_id or not campaign_id: self.redirect('/') else: self.redirect('/showAdGroups?clientCustomerId=%s&campaignId=%s' ...
def post(self): """Handle post request.""" client_customer_id = self.request.get('clientCustomerId') campaign_id = self.request.get('campaignId') if not client_customer_id or not campaign_id: self.redirect('/') else: self.redirect('/showAdGroups?clientCustomerId=%s&campaignId=%s' ...
[ "Handle", "post", "request", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/views/show_adgroups_view.py#L66-L74
[ "def", "post", "(", "self", ")", ":", "client_customer_id", "=", "self", ".", "request", ".", "get", "(", "'clientCustomerId'", ")", "campaign_id", "=", "self", ".", "request", ".", "get", "(", "'campaignId'", ")", "if", "not", "client_customer_id", "or", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ShowCredentials.get
Handle get request.
examples/adwords/adwords_appengine_demo/views/show_credentials_view.py
def get(self): """Handle get request.""" template_values = { 'back_url': '/', 'back_msg': 'View Accounts', 'logout_url': users.create_logout_url('/'), 'user_nickname': users.get_current_user().nickname() } try: try: app_user = InitUser() template_va...
def get(self): """Handle get request.""" template_values = { 'back_url': '/', 'back_msg': 'View Accounts', 'logout_url': users.create_logout_url('/'), 'user_nickname': users.get_current_user().nickname() } try: try: app_user = InitUser() template_va...
[ "Handle", "get", "request", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/views/show_credentials_view.py#L31-L61
[ "def", "get", "(", "self", ")", ":", "template_values", "=", "{", "'back_url'", ":", "'/'", ",", "'back_msg'", ":", "'View Accounts'", ",", "'logout_url'", ":", "users", ".", "create_logout_url", "(", "'/'", ")", ",", "'user_nickname'", ":", "users", ".", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_CreateBudget
Creates the budget. Args: client: an AdWordsClient instance. Returns: a suds.sudsobject.Object representation of the created budget.
examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py
def _CreateBudget(client): """Creates the budget. Args: client: an AdWordsClient instance. Returns: a suds.sudsobject.Object representation of the created budget. """ budget_service = client.GetService('BudgetService', version='v201809') # Create the campaign budget operation = { 'operand...
def _CreateBudget(client): """Creates the budget. Args: client: an AdWordsClient instance. Returns: a suds.sudsobject.Object representation of the created budget. """ budget_service = client.GetService('BudgetService', version='v201809') # Create the campaign budget operation = { 'operand...
[ "Creates", "the", "budget", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py#L43-L71
[ "def", "_CreateBudget", "(", "client", ")", ":", "budget_service", "=", "client", ".", "GetService", "(", "'BudgetService'", ",", "version", "=", "'v201809'", ")", "# Create the campaign budget", "operation", "=", "{", "'operand'", ":", "{", "'name'", ":", "'Int...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_CreateCampaign
Creates the campaign. Args: client: an AdWordsClient instance. budget: a suds.sudsobject.Object representation of a created budget. Returns: An integer campaign ID.
examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py
def _CreateCampaign(client, budget): """Creates the campaign. Args: client: an AdWordsClient instance. budget: a suds.sudsobject.Object representation of a created budget. Returns: An integer campaign ID. """ campaign_service = client.GetService('CampaignService') operations = [{ 'opera...
def _CreateCampaign(client, budget): """Creates the campaign. Args: client: an AdWordsClient instance. budget: a suds.sudsobject.Object representation of a created budget. Returns: An integer campaign ID. """ campaign_service = client.GetService('CampaignService') operations = [{ 'opera...
[ "Creates", "the", "campaign", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py#L74-L121
[ "def", "_CreateCampaign", "(", "client", ",", "budget", ")", ":", "campaign_service", "=", "client", ".", "GetService", "(", "'CampaignService'", ")", "operations", "=", "[", "{", "'operator'", ":", "'ADD'", ",", "'operand'", ":", "{", "'name'", ":", "'Inter...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_CreateAdGroup
Creates an ad group. Args: client: an AdWordsClient instance. campaign_id: an integer campaign ID. Returns: An integer ad group ID.
examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py
def _CreateAdGroup(client, campaign_id): """Creates an ad group. Args: client: an AdWordsClient instance. campaign_id: an integer campaign ID. Returns: An integer ad group ID. """ ad_group_service = client.GetService('AdGroupService') operations = [{ 'operator': 'ADD', 'operand': ...
def _CreateAdGroup(client, campaign_id): """Creates an ad group. Args: client: an AdWordsClient instance. campaign_id: an integer campaign ID. Returns: An integer ad group ID. """ ad_group_service = client.GetService('AdGroupService') operations = [{ 'operator': 'ADD', 'operand': ...
[ "Creates", "an", "ad", "group", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py#L124-L160
[ "def", "_CreateAdGroup", "(", "client", ",", "campaign_id", ")", ":", "ad_group_service", "=", "client", ".", "GetService", "(", "'AdGroupService'", ")", "operations", "=", "[", "{", "'operator'", ":", "'ADD'", ",", "'operand'", ":", "{", "'campaignId'", ":", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_CreateExpandedDSA
Creates the expanded Dynamic Search Ad. Args: client: an AdwordsClient instance. ad_group_id: an integer ID of the ad group in which the DSA is added.
examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py
def _CreateExpandedDSA(client, ad_group_id): """Creates the expanded Dynamic Search Ad. Args: client: an AdwordsClient instance. ad_group_id: an integer ID of the ad group in which the DSA is added. """ # Get the AdGroupAdService. ad_group_ad_service = client.GetService('AdGroupAdService') # Creat...
def _CreateExpandedDSA(client, ad_group_id): """Creates the expanded Dynamic Search Ad. Args: client: an AdwordsClient instance. ad_group_id: an integer ID of the ad group in which the DSA is added. """ # Get the AdGroupAdService. ad_group_ad_service = client.GetService('AdGroupAdService') # Creat...
[ "Creates", "the", "expanded", "Dynamic", "Search", "Ad", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py#L163-L200
[ "def", "_CreateExpandedDSA", "(", "client", ",", "ad_group_id", ")", ":", "# Get the AdGroupAdService.", "ad_group_ad_service", "=", "client", ".", "GetService", "(", "'AdGroupAdService'", ")", "# Create the operation", "operations", "=", "[", "{", "'operator'", ":", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_AddWebPageCriteria
Adds a web page criterion to target Dynamic Search Ads. Args: client: an AdWordsClient instance. ad_group_id: an integer ID of the ad group the criteria is being added to.
examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py
def _AddWebPageCriteria(client, ad_group_id): """Adds a web page criterion to target Dynamic Search Ads. Args: client: an AdWordsClient instance. ad_group_id: an integer ID of the ad group the criteria is being added to. """ ad_group_criterion_service = client.GetService('AdGroupCriterionService', ...
def _AddWebPageCriteria(client, ad_group_id): """Adds a web page criterion to target Dynamic Search Ads. Args: client: an AdWordsClient instance. ad_group_id: an integer ID of the ad group the criteria is being added to. """ ad_group_criterion_service = client.GetService('AdGroupCriterionService', ...
[ "Adds", "a", "web", "page", "criterion", "to", "target", "Dynamic", "Search", "Ads", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/advanced_operations/add_dynamic_search_ads_campaign.py#L203-L252
[ "def", "_AddWebPageCriteria", "(", "client", ",", "ad_group_id", ")", ":", "ad_group_criterion_service", "=", "client", ".", "GetService", "(", "'AdGroupCriterionService'", ",", "version", "=", "'v201809'", ")", "operations", "=", "[", "{", "'operator'", ":", "'AD...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
UploadImageAsset
Uploads the image from the specified url. Args: client: An AdWordsClient instance. url: The image URL. Returns: The ID of the uploaded image.
examples/adwords/v201809/advanced_operations/add_multi_asset_responsive_display_ad.py
def UploadImageAsset(client, url): """Uploads the image from the specified url. Args: client: An AdWordsClient instance. url: The image URL. Returns: The ID of the uploaded image. """ # Initialize appropriate service. asset_service = client.GetService('AssetService', version='v201809') # Do...
def UploadImageAsset(client, url): """Uploads the image from the specified url. Args: client: An AdWordsClient instance. url: The image URL. Returns: The ID of the uploaded image. """ # Initialize appropriate service. asset_service = client.GetService('AssetService', version='v201809') # Do...
[ "Uploads", "the", "image", "from", "the", "specified", "url", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/advanced_operations/add_multi_asset_responsive_display_ad.py#L37-L70
[ "def", "UploadImageAsset", "(", "client", ",", "url", ")", ":", "# Initialize appropriate service.", "asset_service", "=", "client", ".", "GetService", "(", "'AssetService'", ",", "version", "=", "'v201809'", ")", "# Download the image.", "image_request", "=", "reques...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GenerateLibSig
Generates a library signature suitable for a user agent field. Args: short_name: The short, product-specific string name for the library. Returns: A library signature string to append to user-supplied user-agent value.
googleads/common.py
def GenerateLibSig(short_name): """Generates a library signature suitable for a user agent field. Args: short_name: The short, product-specific string name for the library. Returns: A library signature string to append to user-supplied user-agent value. """ with _UTILITY_LOCK: utilities_used = ',...
def GenerateLibSig(short_name): """Generates a library signature suitable for a user agent field. Args: short_name: The short, product-specific string name for the library. Returns: A library signature string to append to user-supplied user-agent value. """ with _UTILITY_LOCK: utilities_used = ',...
[ "Generates", "a", "library", "signature", "suitable", "for", "a", "user", "agent", "field", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L118-L135
[ "def", "GenerateLibSig", "(", "short_name", ")", ":", "with", "_UTILITY_LOCK", ":", "utilities_used", "=", "', '", ".", "join", "(", "[", "utility", "for", "utility", "in", "sorted", "(", "_utility_registry", ")", "]", ")", "_utility_registry", ".", "Clear", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
LoadFromString
Loads the data necessary for instantiating a client from file storage. In addition to the required_client_values argument, the yaml file must supply the keys used to create OAuth2 credentials. It may also optionally set proxy configurations. Args: yaml_doc: the yaml document whose keys should be used. ...
googleads/common.py
def LoadFromString(yaml_doc, product_yaml_key, required_client_values, optional_product_values): """Loads the data necessary for instantiating a client from file storage. In addition to the required_client_values argument, the yaml file must supply the keys used to create OAuth2 credentials. I...
def LoadFromString(yaml_doc, product_yaml_key, required_client_values, optional_product_values): """Loads the data necessary for instantiating a client from file storage. In addition to the required_client_values argument, the yaml file must supply the keys used to create OAuth2 credentials. I...
[ "Loads", "the", "data", "necessary", "for", "instantiating", "a", "client", "from", "file", "storage", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L158-L245
[ "def", "LoadFromString", "(", "yaml_doc", ",", "product_yaml_key", ",", "required_client_values", ",", "optional_product_values", ")", ":", "data", "=", "yaml", ".", "safe_load", "(", "yaml_doc", ")", "or", "{", "}", "if", "'dfp'", "in", "data", ":", "raise", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
LoadFromStorage
Loads the data necessary for instantiating a client from file storage. In addition to the required_client_values argument, the yaml file must supply the keys used to create OAuth2 credentials. It may also optionally set proxy configurations. Args: path: A path string to the yaml document whose keys should...
googleads/common.py
def LoadFromStorage(path, product_yaml_key, required_client_values, optional_product_values): """Loads the data necessary for instantiating a client from file storage. In addition to the required_client_values argument, the yaml file must supply the keys used to create OAuth2 credentials. It ...
def LoadFromStorage(path, product_yaml_key, required_client_values, optional_product_values): """Loads the data necessary for instantiating a client from file storage. In addition to the required_client_values argument, the yaml file must supply the keys used to create OAuth2 credentials. It ...
[ "Loads", "the", "data", "necessary", "for", "instantiating", "a", "client", "from", "file", "storage", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L248-L294
[ "def", "LoadFromStorage", "(", "path", ",", "product_yaml_key", ",", "required_client_values", ",", "optional_product_values", ")", ":", "if", "not", "os", ".", "path", ".", "isabs", "(", "path", ")", ":", "path", "=", "os", ".", "path", ".", "expanduser", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_ExtractOAuth2Client
Generates an GoogleOAuth2Client subclass using the given product_data. Args: product_yaml_key: a string key identifying the product being configured. product_data: a dict containing the configurations for a given product. proxy_config: a ProxyConfig instance. Returns: An instantiated GoogleOAuth2C...
googleads/common.py
def _ExtractOAuth2Client(product_yaml_key, product_data, proxy_config): """Generates an GoogleOAuth2Client subclass using the given product_data. Args: product_yaml_key: a string key identifying the product being configured. product_data: a dict containing the configurations for a given product. proxy_...
def _ExtractOAuth2Client(product_yaml_key, product_data, proxy_config): """Generates an GoogleOAuth2Client subclass using the given product_data. Args: product_yaml_key: a string key identifying the product being configured. product_data: a dict containing the configurations for a given product. proxy_...
[ "Generates", "an", "GoogleOAuth2Client", "subclass", "using", "the", "given", "product_data", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L297-L345
[ "def", "_ExtractOAuth2Client", "(", "product_yaml_key", ",", "product_data", ",", "proxy_config", ")", ":", "oauth2_kwargs", "=", "{", "'proxy_config'", ":", "proxy_config", "}", "if", "all", "(", "config", "in", "product_data", "for", "config", "in", "_OAUTH2_INS...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_ExtractProxyConfig
Returns an initialized ProxyConfig using the given proxy_config_data. Args: product_yaml_key: a string indicating the client being loaded. proxy_config_data: a dict containing the contents of proxy_config from the YAML file. Returns: If there is a proxy to configure in proxy_config, this will re...
googleads/common.py
def _ExtractProxyConfig(product_yaml_key, proxy_config_data): """Returns an initialized ProxyConfig using the given proxy_config_data. Args: product_yaml_key: a string indicating the client being loaded. proxy_config_data: a dict containing the contents of proxy_config from the YAML file. Returns:...
def _ExtractProxyConfig(product_yaml_key, proxy_config_data): """Returns an initialized ProxyConfig using the given proxy_config_data. Args: product_yaml_key: a string indicating the client being loaded. proxy_config_data: a dict containing the contents of proxy_config from the YAML file. Returns:...
[ "Returns", "an", "initialized", "ProxyConfig", "using", "the", "given", "proxy_config_data", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L348-L376
[ "def", "_ExtractProxyConfig", "(", "product_yaml_key", ",", "proxy_config_data", ")", ":", "cafile", "=", "proxy_config_data", ".", "get", "(", "'cafile'", ",", "None", ")", "disable_certificate_validation", "=", "proxy_config_data", ".", "get", "(", "'disable_certifi...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_PackForSuds
Packs SOAP input into the format we want for suds. The main goal here is to pack dictionaries with an 'xsi_type' key into objects. This allows dictionary syntax to be used even with complex types extending other complex types. The contents of dictionaries and lists/tuples are recursively packed. Mutable types ...
googleads/common.py
def _PackForSuds(obj, factory, packer=None, version=None): """Packs SOAP input into the format we want for suds. The main goal here is to pack dictionaries with an 'xsi_type' key into objects. This allows dictionary syntax to be used even with complex types extending other complex types. The contents of dictio...
def _PackForSuds(obj, factory, packer=None, version=None): """Packs SOAP input into the format we want for suds. The main goal here is to pack dictionaries with an 'xsi_type' key into objects. This allows dictionary syntax to be used even with complex types extending other complex types. The contents of dictio...
[ "Packs", "SOAP", "input", "into", "the", "format", "we", "want", "for", "suds", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L379-L449
[ "def", "_PackForSuds", "(", "obj", ",", "factory", ",", "packer", "=", "None", ",", "version", "=", "None", ")", ":", "if", "packer", ":", "obj", "=", "packer", ".", "Pack", "(", "obj", ",", "version", ")", "if", "obj", "in", "(", "{", "}", ",", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_RecurseOverObject
Recurses over a nested structure to look for changes in Suds objects. Args: obj: A parameter for a SOAP request field which is to be inspected and will be packed for Suds if an xsi_type is specified, otherwise will be left unaltered. factory: The suds.client.Factory object which can create in...
googleads/common.py
def _RecurseOverObject(obj, factory, parent=None): """Recurses over a nested structure to look for changes in Suds objects. Args: obj: A parameter for a SOAP request field which is to be inspected and will be packed for Suds if an xsi_type is specified, otherwise will be left unaltered. fac...
def _RecurseOverObject(obj, factory, parent=None): """Recurses over a nested structure to look for changes in Suds objects. Args: obj: A parameter for a SOAP request field which is to be inspected and will be packed for Suds if an xsi_type is specified, otherwise will be left unaltered. fac...
[ "Recurses", "over", "a", "nested", "structure", "to", "look", "for", "changes", "in", "Suds", "objects", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L452-L475
[ "def", "_RecurseOverObject", "(", "obj", ",", "factory", ",", "parent", "=", "None", ")", ":", "if", "_IsSudsIterable", "(", "obj", ")", ":", "# Since in-place modification of the Suds object is taking place, the", "# iterator should be done over a frozen copy of the unpacked f...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
RegisterUtility
Decorator that registers a class with the given utility name. This will only register the utilities being used if the UtilityRegistry is enabled. Note that only the utility class's public methods will cause the utility name to be added to the registry. Args: utility_name: A str specifying the utility name...
googleads/common.py
def RegisterUtility(utility_name, version_mapping=None): """Decorator that registers a class with the given utility name. This will only register the utilities being used if the UtilityRegistry is enabled. Note that only the utility class's public methods will cause the utility name to be added to the registry...
def RegisterUtility(utility_name, version_mapping=None): """Decorator that registers a class with the given utility name. This will only register the utilities being used if the UtilityRegistry is enabled. Note that only the utility class's public methods will cause the utility name to be added to the registry...
[ "Decorator", "that", "registers", "a", "class", "with", "the", "given", "utility", "name", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L504-L559
[ "def", "RegisterUtility", "(", "utility_name", ",", "version_mapping", "=", "None", ")", ":", "def", "IsFunctionOrMethod", "(", "member", ")", ":", "\"\"\"Determines if given member is a function or method.\n\n These two are used in combination to ensure that inspect finds all of ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_ExtractRequestSummaryFields
Extract logging fields from the request's suds.sax.element.Element. Args: document: A suds.sax.element.Element instance containing the API request. Returns: A dict mapping logging field names to their corresponding value.
googleads/common.py
def _ExtractRequestSummaryFields(document): """Extract logging fields from the request's suds.sax.element.Element. Args: document: A suds.sax.element.Element instance containing the API request. Returns: A dict mapping logging field names to their corresponding value. """ headers = document.childAtP...
def _ExtractRequestSummaryFields(document): """Extract logging fields from the request's suds.sax.element.Element. Args: document: A suds.sax.element.Element instance containing the API request. Returns: A dict mapping logging field names to their corresponding value. """ headers = document.childAtP...
[ "Extract", "logging", "fields", "from", "the", "request", "s", "suds", ".", "sax", ".", "element", ".", "Element", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1429-L1457
[ "def", "_ExtractRequestSummaryFields", "(", "document", ")", ":", "headers", "=", "document", ".", "childAtPath", "(", "'Header/RequestHeader'", ")", "body", "=", "document", ".", "childAtPath", "(", "'Body'", ")", "summary_fields", "=", "{", "'methodName'", ":", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_ExtractResponseSummaryFields
Extract logging fields from the response's suds.sax.document.Document. Args: document: A suds.sax.document.Document instance containing the parsed API response for a given API request. Returns: A dict mapping logging field names to their corresponding value.
googleads/common.py
def _ExtractResponseSummaryFields(document): """Extract logging fields from the response's suds.sax.document.Document. Args: document: A suds.sax.document.Document instance containing the parsed API response for a given API request. Returns: A dict mapping logging field names to their correspondin...
def _ExtractResponseSummaryFields(document): """Extract logging fields from the response's suds.sax.document.Document. Args: document: A suds.sax.document.Document instance containing the parsed API response for a given API request. Returns: A dict mapping logging field names to their correspondin...
[ "Extract", "logging", "fields", "from", "the", "response", "s", "suds", ".", "sax", ".", "document", ".", "Document", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1460-L1503
[ "def", "_ExtractResponseSummaryFields", "(", "document", ")", ":", "headers", "=", "document", ".", "childAtPath", "(", "'Envelope/Header/ResponseHeader'", ")", "body", "=", "document", ".", "childAtPath", "(", "'Envelope/Body'", ")", "summary_fields", "=", "{", "}"...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ProxyConfig._InitSSLContext
Creates a ssl.SSLContext with the given settings. Args: cafile: A str identifying the resolved path to the cafile. If not set, this will use the system default cafile. disable_ssl_certificate_validation: A boolean indicating whether certificate verification is disabled. For security pur...
googleads/common.py
def _InitSSLContext(self, cafile=None, disable_ssl_certificate_validation=False): """Creates a ssl.SSLContext with the given settings. Args: cafile: A str identifying the resolved path to the cafile. If not set, this will use the system default cafile. disable_ssl_cert...
def _InitSSLContext(self, cafile=None, disable_ssl_certificate_validation=False): """Creates a ssl.SSLContext with the given settings. Args: cafile: A str identifying the resolved path to the cafile. If not set, this will use the system default cafile. disable_ssl_cert...
[ "Creates", "a", "ssl", ".", "SSLContext", "with", "the", "given", "settings", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L582-L612
[ "def", "_InitSSLContext", "(", "self", ",", "cafile", "=", "None", ",", "disable_ssl_certificate_validation", "=", "False", ")", ":", "# Attempt to create a context; this should succeed in Python 2 versions", "# 2.7.9+ and Python 3 versions 3.4+.", "try", ":", "if", "disable_ss...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ProxyConfig.GetHandlers
Retrieve the appropriate urllib2 handlers for the given configuration. Returns: A list of urllib2.BaseHandler subclasses to be used when making calls with proxy.
googleads/common.py
def GetHandlers(self): """Retrieve the appropriate urllib2 handlers for the given configuration. Returns: A list of urllib2.BaseHandler subclasses to be used when making calls with proxy. """ handlers = [] if self.ssl_context: handlers.append(urllib2.HTTPSHandler(context=self.ssl...
def GetHandlers(self): """Retrieve the appropriate urllib2 handlers for the given configuration. Returns: A list of urllib2.BaseHandler subclasses to be used when making calls with proxy. """ handlers = [] if self.ssl_context: handlers.append(urllib2.HTTPSHandler(context=self.ssl...
[ "Retrieve", "the", "appropriate", "urllib2", "handlers", "for", "the", "given", "configuration", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L626-L641
[ "def", "GetHandlers", "(", "self", ")", ":", "handlers", "=", "[", "]", "if", "self", ".", "ssl_context", ":", "handlers", ".", "append", "(", "urllib2", ".", "HTTPSHandler", "(", "context", "=", "self", ".", "ssl_context", ")", ")", "if", "self", ".",...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_SudsProxyTransport.u2handlers
Get a collection of urllib2 handlers to be installed in the opener. Returns: A list of handlers to be installed to the OpenerDirector used by suds.
googleads/common.py
def u2handlers(self): """Get a collection of urllib2 handlers to be installed in the opener. Returns: A list of handlers to be installed to the OpenerDirector used by suds. """ # Start with the default set of handlers. return_handlers = suds.transport.http.HttpTransport.u2handlers(self) r...
def u2handlers(self): """Get a collection of urllib2 handlers to be installed in the opener. Returns: A list of handlers to be installed to the OpenerDirector used by suds. """ # Start with the default set of handlers. return_handlers = suds.transport.http.HttpTransport.u2handlers(self) r...
[ "Get", "a", "collection", "of", "urllib2", "handlers", "to", "be", "installed", "in", "the", "opener", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L690-L700
[ "def", "u2handlers", "(", "self", ")", ":", "# Start with the default set of handlers.", "return_handlers", "=", "suds", ".", "transport", ".", "http", ".", "HttpTransport", ".", "u2handlers", "(", "self", ")", "return_handlers", ".", "extend", "(", "self", ".", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
SudsSchemaHelper.GetSoapXMLForComplexType
Return an XML string representing a SOAP complex type. Args: type_name: The name of the type with namespace prefix if necessary. value: A python dictionary to hydrate the type instance with. Returns: A string containing the SOAP XML for the type.
googleads/common.py
def GetSoapXMLForComplexType(self, type_name, value): """Return an XML string representing a SOAP complex type. Args: type_name: The name of the type with namespace prefix if necessary. value: A python dictionary to hydrate the type instance with. Returns: A string containing the SOAP XM...
def GetSoapXMLForComplexType(self, type_name, value): """Return an XML string representing a SOAP complex type. Args: type_name: The name of the type with namespace prefix if necessary. value: A python dictionary to hydrate the type instance with. Returns: A string containing the SOAP XM...
[ "Return", "an", "XML", "string", "representing", "a", "SOAP", "complex", "type", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L778-L795
[ "def", "GetSoapXMLForComplexType", "(", "self", ",", "type_name", ",", "value", ")", ":", "schema", "=", "self", ".", "suds_client", ".", "wsdl", ".", "schema", "definition_type", "=", "schema", ".", "elements", "[", "(", "type_name", ",", "self", ".", "_n...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepSchemaHelper.GetSoapXMLForComplexType
Return an XML string representing a SOAP complex type. Args: type_name: The name of the type with namespace prefix if necessary. value: A python dictionary to hydrate the type instance with. Returns: A string containing the SOAP XML for the type.
googleads/common.py
def GetSoapXMLForComplexType(self, type_name, value): """Return an XML string representing a SOAP complex type. Args: type_name: The name of the type with namespace prefix if necessary. value: A python dictionary to hydrate the type instance with. Returns: A string containing the SOAP XM...
def GetSoapXMLForComplexType(self, type_name, value): """Return an XML string representing a SOAP complex type. Args: type_name: The name of the type with namespace prefix if necessary. value: A python dictionary to hydrate the type instance with. Returns: A string containing the SOAP XM...
[ "Return", "an", "XML", "string", "representing", "a", "SOAP", "complex", "type", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L831-L847
[ "def", "GetSoapXMLForComplexType", "(", "self", ",", "type_name", ",", "value", ")", ":", "element", "=", "self", ".", "schema", ".", "get_element", "(", "'{%s}%s'", "%", "(", "self", ".", "_namespace_override", ",", "type_name", ")", ")", "result_element", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
SudsServiceProxy.GetRequestXML
Get the raw SOAP XML for a request. Args: method: The method name. *args: A list of arguments to be passed to the method. Returns: An element containing the raw XML that would be sent as the request.
googleads/common.py
def GetRequestXML(self, method, *args): """Get the raw SOAP XML for a request. Args: method: The method name. *args: A list of arguments to be passed to the method. Returns: An element containing the raw XML that would be sent as the request. """ self.suds_client.set_options(nose...
def GetRequestXML(self, method, *args): """Get the raw SOAP XML for a request. Args: method: The method name. *args: A list of arguments to be passed to the method. Returns: An element containing the raw XML that would be sent as the request. """ self.suds_client.set_options(nose...
[ "Get", "the", "raw", "SOAP", "XML", "for", "a", "request", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L986-L999
[ "def", "GetRequestXML", "(", "self", ",", "method", ",", "*", "args", ")", ":", "self", ".", "suds_client", ".", "set_options", "(", "nosend", "=", "True", ")", "service_request", "=", "(", "getattr", "(", "self", ",", "method", ")", ")", "(", "*", "...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
SudsServiceProxy.SetHeaders
Set the headers for the underlying client. Args: soap_headers: A SOAP element for the SOAP headers. http_headers: A dictionary for the http headers.
googleads/common.py
def SetHeaders(self, soap_headers, http_headers): """Set the headers for the underlying client. Args: soap_headers: A SOAP element for the SOAP headers. http_headers: A dictionary for the http headers. """ self.suds_client.set_options(soapheaders=soap_headers, headers=http_headers)
def SetHeaders(self, soap_headers, http_headers): """Set the headers for the underlying client. Args: soap_headers: A SOAP element for the SOAP headers. http_headers: A dictionary for the http headers. """ self.suds_client.set_options(soapheaders=soap_headers, headers=http_headers)
[ "Set", "the", "headers", "for", "the", "underlying", "client", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1012-L1019
[ "def", "SetHeaders", "(", "self", ",", "soap_headers", ",", "http_headers", ")", ":", "self", ".", "suds_client", ".", "set_options", "(", "soapheaders", "=", "soap_headers", ",", "headers", "=", "http_headers", ")" ]
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
SudsServiceProxy._WsdlHasMethod
Determine if the wsdl contains a method. Args: method_name: The name of the method to search. Returns: True if the method is in the WSDL, otherwise False.
googleads/common.py
def _WsdlHasMethod(self, method_name): """Determine if the wsdl contains a method. Args: method_name: The name of the method to search. Returns: True if the method is in the WSDL, otherwise False. """ return method_name in self.suds_client.wsdl.services[0].ports[0].methods
def _WsdlHasMethod(self, method_name): """Determine if the wsdl contains a method. Args: method_name: The name of the method to search. Returns: True if the method is in the WSDL, otherwise False. """ return method_name in self.suds_client.wsdl.services[0].ports[0].methods
[ "Determine", "if", "the", "wsdl", "contains", "a", "method", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1021-L1030
[ "def", "_WsdlHasMethod", "(", "self", ",", "method_name", ")", ":", "return", "method_name", "in", "self", ".", "suds_client", ".", "wsdl", ".", "services", "[", "0", "]", ".", "ports", "[", "0", "]", ".", "methods" ]
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
SudsServiceProxy._CreateMethod
Create a method wrapping an invocation to the SOAP service. Args: method_name: A string identifying the name of the SOAP method to call. Returns: A callable that can be used to make the desired SOAP request.
googleads/common.py
def _CreateMethod(self, method_name): """Create a method wrapping an invocation to the SOAP service. Args: method_name: A string identifying the name of the SOAP method to call. Returns: A callable that can be used to make the desired SOAP request. """ soap_service_method = getattr(sel...
def _CreateMethod(self, method_name): """Create a method wrapping an invocation to the SOAP service. Args: method_name: A string identifying the name of the SOAP method to call. Returns: A callable that can be used to make the desired SOAP request. """ soap_service_method = getattr(sel...
[ "Create", "a", "method", "wrapping", "an", "invocation", "to", "the", "SOAP", "service", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1032-L1082
[ "def", "_CreateMethod", "(", "self", ",", "method_name", ")", ":", "soap_service_method", "=", "getattr", "(", "self", ".", "suds_client", ".", "service", ",", "method_name", ")", "def", "MakeSoapRequest", "(", "*", "args", ")", ":", "\"\"\"Perform a SOAP call.\...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_ZeepAuthHeaderPlugin.egress
Overriding the egress function to set our headers. Args: envelope: An Element with the SOAP request data. http_headers: A dict of the current http headers. operation: The SoapOperation instance. binding_options: An options dict for the SOAP binding. Returns: A tuple of the envelo...
googleads/common.py
def egress(self, envelope, http_headers, operation, binding_options): """Overriding the egress function to set our headers. Args: envelope: An Element with the SOAP request data. http_headers: A dict of the current http headers. operation: The SoapOperation instance. binding_options: An...
def egress(self, envelope, http_headers, operation, binding_options): """Overriding the egress function to set our headers. Args: envelope: An Element with the SOAP request data. http_headers: A dict of the current http headers. operation: The SoapOperation instance. binding_options: An...
[ "Overriding", "the", "egress", "function", "to", "set", "our", "headers", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1096-L1110
[ "def", "egress", "(", "self", ",", "envelope", ",", "http_headers", ",", "operation", ",", "binding_options", ")", ":", "custom_headers", "=", "self", ".", "_header_handler", ".", "GetHTTPHeaders", "(", ")", "http_headers", ".", "update", "(", "custom_headers", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy.GetRequestXML
Get the raw SOAP XML for a request. Args: method: The method name. *args: A list of arguments to be passed to the method. Returns: An element containing the raw XML that would be sent as the request.
googleads/common.py
def GetRequestXML(self, method, *args): """Get the raw SOAP XML for a request. Args: method: The method name. *args: A list of arguments to be passed to the method. Returns: An element containing the raw XML that would be sent as the request. """ packed_args = self._PackArguments...
def GetRequestXML(self, method, *args): """Get the raw SOAP XML for a request. Args: method: The method name. *args: A list of arguments to be passed to the method. Returns: An element containing the raw XML that would be sent as the request. """ packed_args = self._PackArguments...
[ "Get", "the", "raw", "SOAP", "XML", "for", "a", "request", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1182-L1196
[ "def", "GetRequestXML", "(", "self", ",", "method", ",", "*", "args", ")", ":", "packed_args", "=", "self", ".", "_PackArguments", "(", "method", ",", "args", ",", "set_type_attrs", "=", "True", ")", "headers", "=", "self", ".", "_GetZeepFormattedSOAPHeaders...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._WsdlHasMethod
Determine if a method is in the wsdl. Args: method_name: The name of the method. Returns: True if the method is in the wsdl, otherwise False.
googleads/common.py
def _WsdlHasMethod(self, method_name): """Determine if a method is in the wsdl. Args: method_name: The name of the method. Returns: True if the method is in the wsdl, otherwise False. """ try: self._method_bindings.get(method_name) return True except ValueError: r...
def _WsdlHasMethod(self, method_name): """Determine if a method is in the wsdl. Args: method_name: The name of the method. Returns: True if the method is in the wsdl, otherwise False. """ try: self._method_bindings.get(method_name) return True except ValueError: r...
[ "Determine", "if", "a", "method", "is", "in", "the", "wsdl", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1198-L1211
[ "def", "_WsdlHasMethod", "(", "self", ",", "method_name", ")", ":", "try", ":", "self", ".", "_method_bindings", ".", "get", "(", "method_name", ")", "return", "True", "except", "ValueError", ":", "return", "False" ]
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._GetBindingNamespace
Return a string with the namespace of the service binding in the WSDL.
googleads/common.py
def _GetBindingNamespace(self): """Return a string with the namespace of the service binding in the WSDL.""" return (list(self.zeep_client.wsdl.bindings.itervalues())[0] .port_name.namespace)
def _GetBindingNamespace(self): """Return a string with the namespace of the service binding in the WSDL.""" return (list(self.zeep_client.wsdl.bindings.itervalues())[0] .port_name.namespace)
[ "Return", "a", "string", "with", "the", "namespace", "of", "the", "service", "binding", "in", "the", "WSDL", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1213-L1216
[ "def", "_GetBindingNamespace", "(", "self", ")", ":", "return", "(", "list", "(", "self", ".", "zeep_client", ".", "wsdl", ".", "bindings", ".", "itervalues", "(", ")", ")", "[", "0", "]", ".", "port_name", ".", "namespace", ")" ]
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._PackArguments
Properly pack input dictionaries for zeep. Pack a list of python dictionaries into XML objects. Dictionaries which contain an 'xsi_type' entry are converted into that type instead of the argument default. This allows creation of complex objects which include inherited types. Args: method_nam...
googleads/common.py
def _PackArguments(self, method_name, args, set_type_attrs=False): """Properly pack input dictionaries for zeep. Pack a list of python dictionaries into XML objects. Dictionaries which contain an 'xsi_type' entry are converted into that type instead of the argument default. This allows creation of comp...
def _PackArguments(self, method_name, args, set_type_attrs=False): """Properly pack input dictionaries for zeep. Pack a list of python dictionaries into XML objects. Dictionaries which contain an 'xsi_type' entry are converted into that type instead of the argument default. This allows creation of comp...
[ "Properly", "pack", "input", "dictionaries", "for", "zeep", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1218-L1240
[ "def", "_PackArguments", "(", "self", ",", "method_name", ",", "args", ",", "set_type_attrs", "=", "False", ")", ":", "# Get the params for the method to find the initial types to instantiate.", "op_params", "=", "self", ".", "zeep_client", ".", "get_element", "(", "'{%...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._IsBase64
An imperfect but decent method for determining if a string is base64. Args: s: A string with the data to test. Returns: True if s is base64, else False.
googleads/common.py
def _IsBase64(cls, s): """An imperfect but decent method for determining if a string is base64. Args: s: A string with the data to test. Returns: True if s is base64, else False. """ try: if base64.b64encode(base64.b64decode(s)).decode('utf-8') == s: return True excep...
def _IsBase64(cls, s): """An imperfect but decent method for determining if a string is base64. Args: s: A string with the data to test. Returns: True if s is base64, else False. """ try: if base64.b64encode(base64.b64decode(s)).decode('utf-8') == s: return True excep...
[ "An", "imperfect", "but", "decent", "method", "for", "determining", "if", "a", "string", "is", "base64", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1243-L1257
[ "def", "_IsBase64", "(", "cls", ",", "s", ")", ":", "try", ":", "if", "base64", ".", "b64encode", "(", "base64", ".", "b64decode", "(", "s", ")", ")", ".", "decode", "(", "'utf-8'", ")", "==", "s", ":", "return", "True", "except", "(", "TypeError",...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._PackArgumentsHelper
Recursive helper for PackArguments. Args: elem: The element type we are creating. data: The data to instantiate it with. set_type_attrs: A boolean indicating whether or not attributes that end in .Type should be set. This is only necessary for batch job service. Returns: An ins...
googleads/common.py
def _PackArgumentsHelper(self, elem, data, set_type_attrs): """Recursive helper for PackArguments. Args: elem: The element type we are creating. data: The data to instantiate it with. set_type_attrs: A boolean indicating whether or not attributes that end in .Type should be set. This ...
def _PackArgumentsHelper(self, elem, data, set_type_attrs): """Recursive helper for PackArguments. Args: elem: The element type we are creating. data: The data to instantiate it with. set_type_attrs: A boolean indicating whether or not attributes that end in .Type should be set. This ...
[ "Recursive", "helper", "for", "PackArguments", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1259-L1302
[ "def", "_PackArgumentsHelper", "(", "self", ",", "elem", ",", "data", ",", "set_type_attrs", ")", ":", "if", "self", ".", "_packer", ":", "data", "=", "self", ".", "_packer", ".", "Pack", "(", "data", ",", "self", ".", "_version", ")", "if", "isinstanc...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._DiscoverElementTypeFromLocalname
Searches all namespaces for a type by name. Args: type_localname: The name of the type. Returns: A fully qualified SOAP type with the specified name. Raises: A zeep.exceptions.LookupError if the type cannot be found in any namespace.
googleads/common.py
def _DiscoverElementTypeFromLocalname(self, type_localname): """Searches all namespaces for a type by name. Args: type_localname: The name of the type. Returns: A fully qualified SOAP type with the specified name. Raises: A zeep.exceptions.LookupError if the type cannot be found in ...
def _DiscoverElementTypeFromLocalname(self, type_localname): """Searches all namespaces for a type by name. Args: type_localname: The name of the type. Returns: A fully qualified SOAP type with the specified name. Raises: A zeep.exceptions.LookupError if the type cannot be found in ...
[ "Searches", "all", "namespaces", "for", "a", "type", "by", "name", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1304-L1329
[ "def", "_DiscoverElementTypeFromLocalname", "(", "self", ",", "type_localname", ")", ":", "elem_type", "=", "None", "last_exception", "=", "None", "for", "ns_prefix", "in", "self", ".", "zeep_client", ".", "wsdl", ".", "types", ".", "prefix_map", ".", "values", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._CreateComplexTypeFromData
Initialize a SOAP element with specific data. Args: elem_type: The type of the element to create. type_is_override: A boolean specifying if the type is being overridden. data: The data to hydrate the type with. set_type_attrs: A boolean indicating whether or not attributes that end ...
googleads/common.py
def _CreateComplexTypeFromData( self, elem_type, type_is_override, data, set_type_attrs): """Initialize a SOAP element with specific data. Args: elem_type: The type of the element to create. type_is_override: A boolean specifying if the type is being overridden. data: The data to hydrat...
def _CreateComplexTypeFromData( self, elem_type, type_is_override, data, set_type_attrs): """Initialize a SOAP element with specific data. Args: elem_type: The type of the element to create. type_is_override: A boolean specifying if the type is being overridden. data: The data to hydrat...
[ "Initialize", "a", "SOAP", "element", "with", "specific", "data", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1331-L1358
[ "def", "_CreateComplexTypeFromData", "(", "self", ",", "elem_type", ",", "type_is_override", ",", "data", ",", "set_type_attrs", ")", ":", "elem_arguments", "=", "dict", "(", "elem_type", ".", "elements", ")", "# A post order traversal of the original data, need to instan...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._GetZeepFormattedSOAPHeaders
Returns a dict with SOAP headers in the right format for zeep.
googleads/common.py
def _GetZeepFormattedSOAPHeaders(self): """Returns a dict with SOAP headers in the right format for zeep.""" headers = self._header_handler.GetSOAPHeaders(self.CreateSoapElementForType) soap_headers = {'RequestHeader': headers} return soap_headers
def _GetZeepFormattedSOAPHeaders(self): """Returns a dict with SOAP headers in the right format for zeep.""" headers = self._header_handler.GetSOAPHeaders(self.CreateSoapElementForType) soap_headers = {'RequestHeader': headers} return soap_headers
[ "Returns", "a", "dict", "with", "SOAP", "headers", "in", "the", "right", "format", "for", "zeep", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1361-L1365
[ "def", "_GetZeepFormattedSOAPHeaders", "(", "self", ")", ":", "headers", "=", "self", ".", "_header_handler", ".", "GetSOAPHeaders", "(", "self", ".", "CreateSoapElementForType", ")", "soap_headers", "=", "{", "'RequestHeader'", ":", "headers", "}", "return", "soa...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
ZeepServiceProxy._CreateMethod
Create a method wrapping an invocation to the SOAP service. Args: method_name: A string identifying the name of the SOAP method to call. Returns: A callable that can be used to make the desired SOAP request.
googleads/common.py
def _CreateMethod(self, method_name): """Create a method wrapping an invocation to the SOAP service. Args: method_name: A string identifying the name of the SOAP method to call. Returns: A callable that can be used to make the desired SOAP request. """ soap_service_method = self.zeep_c...
def _CreateMethod(self, method_name): """Create a method wrapping an invocation to the SOAP service. Args: method_name: A string identifying the name of the SOAP method to call. Returns: A callable that can be used to make the desired SOAP request. """ soap_service_method = self.zeep_c...
[ "Create", "a", "method", "wrapping", "an", "invocation", "to", "the", "SOAP", "service", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/common.py#L1367-L1397
[ "def", "_CreateMethod", "(", "self", ",", "method_name", ")", ":", "soap_service_method", "=", "self", ".", "zeep_client", ".", "service", "[", "method_name", "]", "def", "MakeSoapRequest", "(", "*", "args", ")", ":", "AddToUtilityRegistry", "(", "'zeep'", ")"...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
main
Runs the example.
examples/adwords/v201809/shopping/add_product_partition_tree.py
def main(client, adgroup_id): """Runs the example.""" adgroup_criterion_service = client.GetService( 'AdGroupCriterionService', version='v201809') helper = ProductPartitionHelper(adgroup_id) # The most trivial partition tree has only a unit node as the root, e.g.: # helper.CreateUnit(bid_amount=100000...
def main(client, adgroup_id): """Runs the example.""" adgroup_criterion_service = client.GetService( 'AdGroupCriterionService', version='v201809') helper = ProductPartitionHelper(adgroup_id) # The most trivial partition tree has only a unit node as the root, e.g.: # helper.CreateUnit(bid_amount=100000...
[ "Runs", "the", "example", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_product_partition_tree.py#L156-L241
[ "def", "main", "(", "client", ",", "adgroup_id", ")", ":", "adgroup_criterion_service", "=", "client", ".", "GetService", "(", "'AdGroupCriterionService'", ",", "version", "=", "'v201809'", ")", "helper", "=", "ProductPartitionHelper", "(", "adgroup_id", ")", "# T...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DisplayTree
Recursively display a node and each of its children. Args: node: The node we're displaying the children of. children: Children of the parent node. level: How deep in the tree we are.
examples/adwords/v201809/shopping/add_product_partition_tree.py
def DisplayTree(node, children, level=0): """Recursively display a node and each of its children. Args: node: The node we're displaying the children of. children: Children of the parent node. level: How deep in the tree we are. """ value = '' node_type = '' if 'caseValue' in node: case_val...
def DisplayTree(node, children, level=0): """Recursively display a node and each of its children. Args: node: The node we're displaying the children of. children: Children of the parent node. level: How deep in the tree we are. """ value = '' node_type = '' if 'caseValue' in node: case_val...
[ "Recursively", "display", "a", "node", "and", "each", "of", "its", "children", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/shopping/add_product_partition_tree.py#L244-L272
[ "def", "DisplayTree", "(", "node", ",", "children", ",", "level", "=", "0", ")", ":", "value", "=", "''", "node_type", "=", "''", "if", "'caseValue'", "in", "node", ":", "case_value", "=", "node", "[", "'caseValue'", "]", "node_type", "=", "case_value", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
get_all_ad_units
Download all ad units. Args: inventory_service: An instance of the InventoryService. Returns: A list containing all ad units.
examples/ad_manager/v201811/inventory_service/get_ad_unit_hierarchy.py
def get_all_ad_units(inventory_service): """Download all ad units. Args: inventory_service: An instance of the InventoryService. Returns: A list containing all ad units. """ # Create a statement to get all ad units. statement = (ad_manager.StatementBuilder(version='v201811') .OrderB...
def get_all_ad_units(inventory_service): """Download all ad units. Args: inventory_service: An instance of the InventoryService. Returns: A list containing all ad units. """ # Create a statement to get all ad units. statement = (ad_manager.StatementBuilder(version='v201811') .OrderB...
[ "Download", "all", "ad", "units", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/ad_manager/v201811/inventory_service/get_ad_unit_hierarchy.py#L50-L76
[ "def", "get_all_ad_units", "(", "inventory_service", ")", ":", "# Create a statement to get all ad units.", "statement", "=", "(", "ad_manager", ".", "StatementBuilder", "(", "version", "=", "'v201811'", ")", ".", "OrderBy", "(", "'id'", ",", "ascending", "=", "True...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
display_hierarchy
Display the ad units as a tree. Args: root_ad_unit: The root ad unit to begin from. all_ad_units: A list containing all ad units.
examples/ad_manager/v201811/inventory_service/get_ad_unit_hierarchy.py
def display_hierarchy(root_ad_unit, all_ad_units): """Display the ad units as a tree. Args: root_ad_unit: The root ad unit to begin from. all_ad_units: A list containing all ad units. """ # Create a dict mapping the ids of parents to lists of their children. parent_id_to_children = collections.defaul...
def display_hierarchy(root_ad_unit, all_ad_units): """Display the ad units as a tree. Args: root_ad_unit: The root ad unit to begin from. all_ad_units: A list containing all ad units. """ # Create a dict mapping the ids of parents to lists of their children. parent_id_to_children = collections.defaul...
[ "Display", "the", "ad", "units", "as", "a", "tree", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/ad_manager/v201811/inventory_service/get_ad_unit_hierarchy.py#L79-L93
[ "def", "display_hierarchy", "(", "root_ad_unit", ",", "all_ad_units", ")", ":", "# Create a dict mapping the ids of parents to lists of their children.", "parent_id_to_children", "=", "collections", ".", "defaultdict", "(", "list", ")", "for", "ad_unit", "in", "all_ad_units",...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
display_hierarchy_helper
Recursive helper for displaying the hierarchy. Args: root: The current root ad unit. parent_id_to_children: The overall map of parent ids to children. depth: The current depth.
examples/ad_manager/v201811/inventory_service/get_ad_unit_hierarchy.py
def display_hierarchy_helper(root, parent_id_to_children, depth): """Recursive helper for displaying the hierarchy. Args: root: The current root ad unit. parent_id_to_children: The overall map of parent ids to children. depth: The current depth. """ print '%s%s (%s)' % ('%s+--' % ('|'.join([' '] *...
def display_hierarchy_helper(root, parent_id_to_children, depth): """Recursive helper for displaying the hierarchy. Args: root: The current root ad unit. parent_id_to_children: The overall map of parent ids to children. depth: The current depth. """ print '%s%s (%s)' % ('%s+--' % ('|'.join([' '] *...
[ "Recursive", "helper", "for", "displaying", "the", "hierarchy", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/ad_manager/v201811/inventory_service/get_ad_unit_hierarchy.py#L96-L109
[ "def", "display_hierarchy_helper", "(", "root", ",", "parent_id_to_children", ",", "depth", ")", ":", "print", "'%s%s (%s)'", "%", "(", "'%s+--'", "%", "(", "'|'", ".", "join", "(", "[", "' '", "]", "*", "depth", ")", ")", ",", "root", "[", "'name'", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_CreateCampaignGroup
Create a campaign group. Args: client: an AdWordsClient instance. Returns: The integer ID of the created campaign group.
examples/adwords/v201809/campaign_management/add_campaign_groups_and_performance_targets.py
def _CreateCampaignGroup(client): """Create a campaign group. Args: client: an AdWordsClient instance. Returns: The integer ID of the created campaign group. """ # Get the CampaignGroupService. campaign_group_service = client.GetService('CampaignGroupService', ...
def _CreateCampaignGroup(client): """Create a campaign group. Args: client: an AdWordsClient instance. Returns: The integer ID of the created campaign group. """ # Get the CampaignGroupService. campaign_group_service = client.GetService('CampaignGroupService', ...
[ "Create", "a", "campaign", "group", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_campaign_groups_and_performance_targets.py#L44-L73
[ "def", "_CreateCampaignGroup", "(", "client", ")", ":", "# Get the CampaignGroupService.", "campaign_group_service", "=", "client", ".", "GetService", "(", "'CampaignGroupService'", ",", "version", "=", "'v201809'", ")", "# Create the operation.", "operations", "=", "[", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_AddCampaignsToGroup
Adds multiple campaigns to a campaign group. Args: client: an AdWordsClient instance. campaign_group_id: an integer ID for the campaign group. campaign_ids: a list of integer IDs for campaigns.
examples/adwords/v201809/campaign_management/add_campaign_groups_and_performance_targets.py
def _AddCampaignsToGroup(client, campaign_group_id, campaign_ids): """Adds multiple campaigns to a campaign group. Args: client: an AdWordsClient instance. campaign_group_id: an integer ID for the campaign group. campaign_ids: a list of integer IDs for campaigns. """ # Get the CampaignService. ca...
def _AddCampaignsToGroup(client, campaign_group_id, campaign_ids): """Adds multiple campaigns to a campaign group. Args: client: an AdWordsClient instance. campaign_group_id: an integer ID for the campaign group. campaign_ids: a list of integer IDs for campaigns. """ # Get the CampaignService. ca...
[ "Adds", "multiple", "campaigns", "to", "a", "campaign", "group", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_campaign_groups_and_performance_targets.py#L76-L100
[ "def", "_AddCampaignsToGroup", "(", "client", ",", "campaign_group_id", ",", "campaign_ids", ")", ":", "# Get the CampaignService.", "campaign_service", "=", "client", ".", "GetService", "(", "'CampaignService'", ",", "version", "=", "'v201809'", ")", "# Create the oper...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_CreatePerformanceTarget
Creates a performance target for the campaign group. Args: client: an AdWordsClient instance. campaign_group_id: an integer ID for the campaign group.
examples/adwords/v201809/campaign_management/add_campaign_groups_and_performance_targets.py
def _CreatePerformanceTarget(client, campaign_group_id): """Creates a performance target for the campaign group. Args: client: an AdWordsClient instance. campaign_group_id: an integer ID for the campaign group. """ # Get the CampaignGroupPerformanceTargetService. cgpt_service = client.GetService('Cam...
def _CreatePerformanceTarget(client, campaign_group_id): """Creates a performance target for the campaign group. Args: client: an AdWordsClient instance. campaign_group_id: an integer ID for the campaign group. """ # Get the CampaignGroupPerformanceTargetService. cgpt_service = client.GetService('Cam...
[ "Creates", "a", "performance", "target", "for", "the", "campaign", "group", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_campaign_groups_and_performance_targets.py#L103-L145
[ "def", "_CreatePerformanceTarget", "(", "client", ",", "campaign_group_id", ")", ":", "# Get the CampaignGroupPerformanceTargetService.", "cgpt_service", "=", "client", ".", "GetService", "(", "'CampaignGroupPerformanceTargetService'", ",", "version", "=", "'v201809'", ")", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
AdManagerClient.GetService
Creates a service client for the given service. Args: service_name: A string identifying which Ad Manager service to create a service client for. [optional] version: A string identifying the Ad Manager version to connect to. This defaults to what is currently the latest versio...
googleads/ad_manager.py
def GetService(self, service_name, version=sorted(_SERVICE_MAP.keys())[-1], server=None): """Creates a service client for the given service. Args: service_name: A string identifying which Ad Manager service to create a service client for. [optional] version: A strin...
def GetService(self, service_name, version=sorted(_SERVICE_MAP.keys())[-1], server=None): """Creates a service client for the given service. Args: service_name: A string identifying which Ad Manager service to create a service client for. [optional] version: A strin...
[ "Creates", "a", "service", "client", "for", "the", "given", "service", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L263-L312
[ "def", "GetService", "(", "self", ",", "service_name", ",", "version", "=", "sorted", "(", "_SERVICE_MAP", ".", "keys", "(", ")", ")", "[", "-", "1", "]", ",", "server", "=", "None", ")", ":", "if", "not", "server", ":", "server", "=", "DEFAULT_ENDPO...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
AdManagerClient.GetDataDownloader
Creates a downloader for Ad Manager reports and PQL result sets. This is a convenience method. It is functionally identical to calling DataDownloader(ad_manager_client, version, server) Args: [optional] version: A string identifying the Ad Manager version to connect to. This defaults...
googleads/ad_manager.py
def GetDataDownloader(self, version=sorted(_SERVICE_MAP.keys())[-1], server=None): """Creates a downloader for Ad Manager reports and PQL result sets. This is a convenience method. It is functionally identical to calling DataDownloader(ad_manager_client, version, server) Args: ...
def GetDataDownloader(self, version=sorted(_SERVICE_MAP.keys())[-1], server=None): """Creates a downloader for Ad Manager reports and PQL result sets. This is a convenience method. It is functionally identical to calling DataDownloader(ad_manager_client, version, server) Args: ...
[ "Creates", "a", "downloader", "for", "Ad", "Manager", "reports", "and", "PQL", "result", "sets", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L314-L335
[ "def", "GetDataDownloader", "(", "self", ",", "version", "=", "sorted", "(", "_SERVICE_MAP", ".", "keys", "(", ")", ")", "[", "-", "1", "]", ",", "server", "=", "None", ")", ":", "if", "not", "server", ":", "server", "=", "DEFAULT_ENDPOINT", "return", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_AdManagerHeaderHandler.GetSOAPHeaders
Returns the SOAP headers required for request authorization. Args: create_method: The SOAP library specific method used to instantiate SOAP objects. Returns: A SOAP object containing the headers.
googleads/ad_manager.py
def GetSOAPHeaders(self, create_method): """Returns the SOAP headers required for request authorization. Args: create_method: The SOAP library specific method used to instantiate SOAP objects. Returns: A SOAP object containing the headers. """ header = create_method(self._SOAP_HE...
def GetSOAPHeaders(self, create_method): """Returns the SOAP headers required for request authorization. Args: create_method: The SOAP library specific method used to instantiate SOAP objects. Returns: A SOAP object containing the headers. """ header = create_method(self._SOAP_HE...
[ "Returns", "the", "SOAP", "headers", "required", "for", "request", "authorization", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L365-L380
[ "def", "GetSOAPHeaders", "(", "self", ",", "create_method", ")", ":", "header", "=", "create_method", "(", "self", ".", "_SOAP_HEADER_CLASS", ")", "header", ".", "networkCode", "=", "self", ".", "_ad_manager_client", ".", "network_code", "header", ".", "applicat...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_AdManagerPacker.Pack
Pack the given object using Ad Manager-specific logic. Args: obj: an object to be packed for SOAP using Ad Manager-specific logic, if applicable. version: the version of the current API, e.g. 'v201811' Returns: The given object packed with Ad Manager-specific logic for SOAP, ...
googleads/ad_manager.py
def Pack(cls, obj, version): """Pack the given object using Ad Manager-specific logic. Args: obj: an object to be packed for SOAP using Ad Manager-specific logic, if applicable. version: the version of the current API, e.g. 'v201811' Returns: The given object packed with Ad Man...
def Pack(cls, obj, version): """Pack the given object using Ad Manager-specific logic. Args: obj: an object to be packed for SOAP using Ad Manager-specific logic, if applicable. version: the version of the current API, e.g. 'v201811' Returns: The given object packed with Ad Man...
[ "Pack", "the", "given", "object", "using", "Ad", "Manager", "-", "specific", "logic", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L401-L415
[ "def", "Pack", "(", "cls", ",", "obj", ",", "version", ")", ":", "if", "isinstance", "(", "obj", ",", "(", "datetime", ".", "datetime", ",", "datetime", ".", "date", ")", ")", ":", "return", "cls", ".", "AdManagerDateTimePacker", "(", "obj", ",", "ve...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
_AdManagerPacker.AdManagerDateTimePacker
Returns dicts formatted for Ad Manager SOAP based on date/datetime. Args: value: A date or datetime object to be converted. version: the version of the current API, e.g. 'v201811' Returns: The value object correctly represented for Ad Manager SOAP.
googleads/ad_manager.py
def AdManagerDateTimePacker(cls, value, version): """Returns dicts formatted for Ad Manager SOAP based on date/datetime. Args: value: A date or datetime object to be converted. version: the version of the current API, e.g. 'v201811' Returns: The value object correctly represented for Ad ...
def AdManagerDateTimePacker(cls, value, version): """Returns dicts formatted for Ad Manager SOAP based on date/datetime. Args: value: A date or datetime object to be converted. version: the version of the current API, e.g. 'v201811' Returns: The value object correctly represented for Ad ...
[ "Returns", "dicts", "formatted", "for", "Ad", "Manager", "SOAP", "based", "on", "date", "/", "datetime", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L418-L444
[ "def", "AdManagerDateTimePacker", "(", "cls", ",", "value", ",", "version", ")", ":", "if", "isinstance", "(", "value", ",", "datetime", ".", "datetime", ")", ":", "if", "value", ".", "tzinfo", "is", "None", ":", "raise", "googleads", ".", "errors", ".",...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
PQLHelper.GetQueryValuesFromDict
Converts a dict of python types into a list of PQL types. Args: d: A dictionary of variable names to python types. version: A string identifying the Ad Manager version the values object is compatible with. This defaults to what is currently the latest version. This will be updated i...
googleads/ad_manager.py
def GetQueryValuesFromDict(cls, d, version=sorted(_SERVICE_MAP.keys())[-1]): """Converts a dict of python types into a list of PQL types. Args: d: A dictionary of variable names to python types. version: A string identifying the Ad Manager version the values object is compatible with. Thi...
def GetQueryValuesFromDict(cls, d, version=sorted(_SERVICE_MAP.keys())[-1]): """Converts a dict of python types into a list of PQL types. Args: d: A dictionary of variable names to python types. version: A string identifying the Ad Manager version the values object is compatible with. Thi...
[ "Converts", "a", "dict", "of", "python", "types", "into", "a", "list", "of", "PQL", "types", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L636-L653
[ "def", "GetQueryValuesFromDict", "(", "cls", ",", "d", ",", "version", "=", "sorted", "(", "_SERVICE_MAP", ".", "keys", "(", ")", ")", "[", "-", "1", "]", ")", ":", "return", "[", "{", "'key'", ":", "key", ",", "'value'", ":", "cls", ".", "GetValue...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
PQLHelper.GetValueRepresentation
Converts a single python value to its PQL representation. Args: value: A python value. version: A string identifying the Ad Manager version the value object is compatible with. This defaults to what is currently the latest version. This will be updated in future releases to point to...
googleads/ad_manager.py
def GetValueRepresentation(cls, value, version=sorted(_SERVICE_MAP.keys())[-1]): """Converts a single python value to its PQL representation. Args: value: A python value. version: A string identifying the Ad Manager version the value object is compatible with....
def GetValueRepresentation(cls, value, version=sorted(_SERVICE_MAP.keys())[-1]): """Converts a single python value to its PQL representation. Args: value: A python value. version: A string identifying the Ad Manager version the value object is compatible with....
[ "Converts", "a", "single", "python", "value", "to", "its", "PQL", "representation", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L656-L720
[ "def", "GetValueRepresentation", "(", "cls", ",", "value", ",", "version", "=", "sorted", "(", "_SERVICE_MAP", ".", "keys", "(", ")", ")", "[", "-", "1", "]", ")", ":", "if", "isinstance", "(", "value", ",", "str", ")", "or", "isinstance", "(", "valu...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader._GetReportService
Lazily initializes a report service client.
googleads/ad_manager.py
def _GetReportService(self): """Lazily initializes a report service client.""" if not self._report_service: self._report_service = self._ad_manager_client.GetService( 'ReportService', self._version, self._server) return self._report_service
def _GetReportService(self): """Lazily initializes a report service client.""" if not self._report_service: self._report_service = self._ad_manager_client.GetService( 'ReportService', self._version, self._server) return self._report_service
[ "Lazily", "initializes", "a", "report", "service", "client", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L779-L784
[ "def", "_GetReportService", "(", "self", ")", ":", "if", "not", "self", ".", "_report_service", ":", "self", ".", "_report_service", "=", "self", ".", "_ad_manager_client", ".", "GetService", "(", "'ReportService'", ",", "self", ".", "_version", ",", "self", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader._GetPqlService
Lazily initializes a PQL service client.
googleads/ad_manager.py
def _GetPqlService(self): """Lazily initializes a PQL service client.""" if not self._pql_service: self._pql_service = self._ad_manager_client.GetService( 'PublisherQueryLanguageService', self._version, self._server) return self._pql_service
def _GetPqlService(self): """Lazily initializes a PQL service client.""" if not self._pql_service: self._pql_service = self._ad_manager_client.GetService( 'PublisherQueryLanguageService', self._version, self._server) return self._pql_service
[ "Lazily", "initializes", "a", "PQL", "service", "client", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L786-L791
[ "def", "_GetPqlService", "(", "self", ")", ":", "if", "not", "self", ".", "_pql_service", ":", "self", ".", "_pql_service", "=", "self", ".", "_ad_manager_client", ".", "GetService", "(", "'PublisherQueryLanguageService'", ",", "self", ".", "_version", ",", "s...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader.WaitForReport
Runs a report, then waits (blocks) for the report to finish generating. Args: report_job: The report job to wait for. This may be a dictionary or an instance of the SOAP ReportJob class. Returns: The completed report job's ID as a string. Raises: An AdManagerReportError if the...
googleads/ad_manager.py
def WaitForReport(self, report_job): """Runs a report, then waits (blocks) for the report to finish generating. Args: report_job: The report job to wait for. This may be a dictionary or an instance of the SOAP ReportJob class. Returns: The completed report job's ID as a string. ...
def WaitForReport(self, report_job): """Runs a report, then waits (blocks) for the report to finish generating. Args: report_job: The report job to wait for. This may be a dictionary or an instance of the SOAP ReportJob class. Returns: The completed report job's ID as a string. ...
[ "Runs", "a", "report", "then", "waits", "(", "blocks", ")", "for", "the", "report", "to", "finish", "generating", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L793-L826
[ "def", "WaitForReport", "(", "self", ",", "report_job", ")", ":", "service", "=", "self", ".", "_GetReportService", "(", ")", "report_job_id", "=", "service", ".", "runReportJob", "(", "report_job", ")", "[", "'id'", "]", "if", "self", ".", "_version", ">"...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader.DownloadReportToFile
Downloads report data and writes it to a file. The report job must be completed before calling this function. Args: report_job_id: The ID of the report job to wait for, as a string. export_format: The export format for the report file, as a string. outfile: A writeable, file-like object to w...
googleads/ad_manager.py
def DownloadReportToFile(self, report_job_id, export_format, outfile, include_report_properties=False, include_totals_row=None, use_gzip_compression=True): """Downloads report data and writes it to a file. The report job must be completed before calling thi...
def DownloadReportToFile(self, report_job_id, export_format, outfile, include_report_properties=False, include_totals_row=None, use_gzip_compression=True): """Downloads report data and writes it to a file. The report job must be completed before calling thi...
[ "Downloads", "report", "data", "and", "writes", "it", "to", "a", "file", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L828-L868
[ "def", "DownloadReportToFile", "(", "self", ",", "report_job_id", ",", "export_format", ",", "outfile", ",", "include_report_properties", "=", "False", ",", "include_totals_row", "=", "None", ",", "use_gzip_compression", "=", "True", ")", ":", "service", "=", "sel...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader.DownloadPqlResultToList
Downloads the results of a PQL query to a list. Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) [optional] values: A dict of python objects or a list of raw SOAP values to bind to the pql_query. Returns: ...
googleads/ad_manager.py
def DownloadPqlResultToList(self, pql_query, values=None): """Downloads the results of a PQL query to a list. Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) [optional] values: A dict of python objects or a list of raw S...
def DownloadPqlResultToList(self, pql_query, values=None): """Downloads the results of a PQL query to a list. Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) [optional] values: A dict of python objects or a list of raw S...
[ "Downloads", "the", "results", "of", "a", "PQL", "query", "to", "a", "list", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L870-L886
[ "def", "DownloadPqlResultToList", "(", "self", ",", "pql_query", ",", "values", "=", "None", ")", ":", "results", "=", "[", "]", "self", ".", "_PageThroughPqlSet", "(", "pql_query", ",", "results", ".", "append", ",", "values", ")", "return", "results" ]
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader.DownloadPqlResultToCsv
Downloads the results of a PQL query to CSV. Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) file_handle: file the file object to write to. [optional] values: A dict of python objects or a list of raw SOAP values to bi...
googleads/ad_manager.py
def DownloadPqlResultToCsv(self, pql_query, file_handle, values=None): """Downloads the results of a PQL query to CSV. Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) file_handle: file the file object to write to. [optio...
def DownloadPqlResultToCsv(self, pql_query, file_handle, values=None): """Downloads the results of a PQL query to CSV. Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) file_handle: file the file object to write to. [optio...
[ "Downloads", "the", "results", "of", "a", "PQL", "query", "to", "CSV", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L888-L901
[ "def", "DownloadPqlResultToCsv", "(", "self", ",", "pql_query", ",", "file_handle", ",", "values", "=", "None", ")", ":", "pql_writer", "=", "csv", ".", "writer", "(", "file_handle", ",", "delimiter", "=", "','", ",", "quotechar", "=", "'\"'", ",", "quotin...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader._ConvertValueForCsv
Sanitizes a field value from a Value object to a CSV suitable format. Args: pql_value: dict a dictionary containing the data for a single field of an entity. Returns: str a CSV writer friendly value formatted by Value.Type.
googleads/ad_manager.py
def _ConvertValueForCsv(self, pql_value): """Sanitizes a field value from a Value object to a CSV suitable format. Args: pql_value: dict a dictionary containing the data for a single field of an entity. Returns: str a CSV writer friendly value formatted by Value.Type. """ ...
def _ConvertValueForCsv(self, pql_value): """Sanitizes a field value from a Value object to a CSV suitable format. Args: pql_value: dict a dictionary containing the data for a single field of an entity. Returns: str a CSV writer friendly value formatted by Value.Type. """ ...
[ "Sanitizes", "a", "field", "value", "from", "a", "Value", "object", "to", "a", "CSV", "suitable", "format", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L903-L951
[ "def", "_ConvertValueForCsv", "(", "self", ",", "pql_value", ")", ":", "if", "'value'", "in", "pql_value", ":", "field", "=", "pql_value", "[", "'value'", "]", "elif", "'values'", "in", "pql_value", ":", "field", "=", "pql_value", "[", "'values'", "]", "el...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader._PageThroughPqlSet
Pages through a pql_query and performs an action (output_function). Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) output_function: the function to call to output the results (csv or in memory) values...
googleads/ad_manager.py
def _PageThroughPqlSet(self, pql_query, output_function, values): """Pages through a pql_query and performs an action (output_function). Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) output_function: the function to call to ...
def _PageThroughPqlSet(self, pql_query, output_function, values): """Pages through a pql_query and performs an action (output_function). Args: pql_query: str a statement filter to apply (the query should not include the limit or the offset) output_function: the function to call to ...
[ "Pages", "through", "a", "pql_query", "and", "performs", "an", "action", "(", "output_function", ")", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L953-L994
[ "def", "_PageThroughPqlSet", "(", "self", ",", "pql_query", ",", "output_function", ",", "values", ")", ":", "if", "isinstance", "(", "values", ",", "dict", ")", ":", "values", "=", "PQLHelper", ".", "GetQueryValuesFromDict", "(", "values", ",", "self", ".",...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DataDownloader._ConvertDateTimeToOffset
Converts the PQL formatted response for a dateTime object. Output conforms to ISO 8061 format, e.g. 'YYYY-MM-DDTHH:MM:SSz.' Args: date_time_value: dict The date time value from the PQL response. Returns: str: A string representation of the date time value uniform to ReportService.
googleads/ad_manager.py
def _ConvertDateTimeToOffset(self, date_time_value): """Converts the PQL formatted response for a dateTime object. Output conforms to ISO 8061 format, e.g. 'YYYY-MM-DDTHH:MM:SSz.' Args: date_time_value: dict The date time value from the PQL response. Returns: str: A string representation ...
def _ConvertDateTimeToOffset(self, date_time_value): """Converts the PQL formatted response for a dateTime object. Output conforms to ISO 8061 format, e.g. 'YYYY-MM-DDTHH:MM:SSz.' Args: date_time_value: dict The date time value from the PQL response. Returns: str: A string representation ...
[ "Converts", "the", "PQL", "formatted", "response", "for", "a", "dateTime", "object", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/googleads/ad_manager.py#L996-L1025
[ "def", "_ConvertDateTimeToOffset", "(", "self", ",", "date_time_value", ")", ":", "date_time_obj", "=", "datetime", ".", "datetime", "(", "int", "(", "date_time_value", "[", "'date'", "]", "[", "'year'", "]", ")", ",", "int", "(", "date_time_value", "[", "'d...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
UpdateCredentials.post
Handle post request.
examples/adwords/adwords_appengine_demo/views/update_credentials_view.py
def post(self): """Handle post request.""" template_values = { 'back_url': '/showCredentials', 'back_msg': 'View Credentials', 'logout_url': users.create_logout_url('/'), 'user_nickname': users.get_current_user().nickname() } try: UpdateUserCredentials(self.request....
def post(self): """Handle post request.""" template_values = { 'back_url': '/showCredentials', 'back_msg': 'View Credentials', 'logout_url': users.create_logout_url('/'), 'user_nickname': users.get_current_user().nickname() } try: UpdateUserCredentials(self.request....
[ "Handle", "post", "request", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/views/update_credentials_view.py#L32-L52
[ "def", "post", "(", "self", ")", ":", "template_values", "=", "{", "'back_url'", ":", "'/showCredentials'", ",", "'back_msg'", ":", "'View Credentials'", ",", "'logout_url'", ":", "users", ".", "create_logout_url", "(", "'/'", ")", ",", "'user_nickname'", ":", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
AddBatchJob
Add a new BatchJob to upload operations to. Args: client: an instantiated AdWordsClient used to retrieve the BatchJob. Returns: The new BatchJob created by the request.
examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py
def AddBatchJob(client): """Add a new BatchJob to upload operations to. Args: client: an instantiated AdWordsClient used to retrieve the BatchJob. Returns: The new BatchJob created by the request. """ # Initialize appropriate service. batch_job_service = client.GetService('BatchJobService', versio...
def AddBatchJob(client): """Add a new BatchJob to upload operations to. Args: client: an instantiated AdWordsClient used to retrieve the BatchJob. Returns: The new BatchJob created by the request. """ # Initialize appropriate service. batch_job_service = client.GetService('BatchJobService', versio...
[ "Add", "a", "new", "BatchJob", "to", "upload", "operations", "to", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py#L70-L86
[ "def", "AddBatchJob", "(", "client", ")", ":", "# Initialize appropriate service.", "batch_job_service", "=", "client", ".", "GetService", "(", "'BatchJobService'", ",", "version", "=", "'v201809'", ")", "# Create a BatchJob.", "batch_job_operations", "=", "[", "{", "...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
BuildAdGroupCriterionOperations
Builds the operations adding a Keyword Criterion to each AdGroup. Args: adgroup_id: an integer identifying an AdGroup to associate the keywords with. Returns: a list containing the operations that will create a new Keyword Criterion associated with each provided AdGroup.
examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py
def BuildAdGroupCriterionOperations(adgroup_id): """Builds the operations adding a Keyword Criterion to each AdGroup. Args: adgroup_id: an integer identifying an AdGroup to associate the keywords with. Returns: a list containing the operations that will create a new Keyword Criterion associate...
def BuildAdGroupCriterionOperations(adgroup_id): """Builds the operations adding a Keyword Criterion to each AdGroup. Args: adgroup_id: an integer identifying an AdGroup to associate the keywords with. Returns: a list containing the operations that will create a new Keyword Criterion associate...
[ "Builds", "the", "operations", "adding", "a", "Keyword", "Criterion", "to", "each", "AdGroup", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py#L89-L120
[ "def", "BuildAdGroupCriterionOperations", "(", "adgroup_id", ")", ":", "criterion_operations", "=", "[", "{", "# You must specify the xsi_type of operations run by the", "# BatchJobService.", "'xsi_type'", ":", "'AdGroupCriterionOperation'", ",", "'operand'", ":", "{", "'xsi_ty...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CancelBatchJob
Cancels the given BatchJob. Args: client: an instantiated AdWordsClient used to cancel the BatchJob. batch_job: a BatchJob to be canceled. max_poll_attempts: an int defining the number of times the BatchJob will be checked to determine whether it has been canceled.
examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py
def CancelBatchJob(client, batch_job, max_poll_attempts=MAX_POLL_ATTEMPTS): """Cancels the given BatchJob. Args: client: an instantiated AdWordsClient used to cancel the BatchJob. batch_job: a BatchJob to be canceled. max_poll_attempts: an int defining the number of times the BatchJob will be che...
def CancelBatchJob(client, batch_job, max_poll_attempts=MAX_POLL_ATTEMPTS): """Cancels the given BatchJob. Args: client: an instantiated AdWordsClient used to cancel the BatchJob. batch_job: a BatchJob to be canceled. max_poll_attempts: an int defining the number of times the BatchJob will be che...
[ "Cancels", "the", "given", "BatchJob", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py#L123-L160
[ "def", "CancelBatchJob", "(", "client", ",", "batch_job", ",", "max_poll_attempts", "=", "MAX_POLL_ATTEMPTS", ")", ":", "batch_job_service", "=", "client", ".", "GetService", "(", "'BatchJobService'", ",", "'v201809'", ")", "batch_job", "[", "'status'", "]", "=", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetBatchJob
Retrieves the BatchJob with the given id. Args: client: an instantiated AdWordsClient used to retrieve the BatchJob. batch_job_id: a long identifying the BatchJob to be retrieved. Returns: The BatchJob associated with the given id.
examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py
def GetBatchJob(client, batch_job_id): """Retrieves the BatchJob with the given id. Args: client: an instantiated AdWordsClient used to retrieve the BatchJob. batch_job_id: a long identifying the BatchJob to be retrieved. Returns: The BatchJob associated with the given id. """ batch_job_service =...
def GetBatchJob(client, batch_job_id): """Retrieves the BatchJob with the given id. Args: client: an instantiated AdWordsClient used to retrieve the BatchJob. batch_job_id: a long identifying the BatchJob to be retrieved. Returns: The BatchJob associated with the given id. """ batch_job_service =...
[ "Retrieves", "the", "BatchJob", "with", "the", "given", "id", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py#L163-L185
[ "def", "GetBatchJob", "(", "client", ",", "batch_job_id", ")", ":", "batch_job_service", "=", "client", ".", "GetService", "(", "'BatchJobService'", ",", "'v201809'", ")", "selector", "=", "{", "'fields'", ":", "[", "'Id'", ",", "'Status'", ",", "'DownloadUrl'...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetBatchJobDownloadUrlWhenReady
Retrieves the downloadUrl when the BatchJob is complete. Args: client: an instantiated AdWordsClient used to poll the BatchJob. batch_job_id: a long identifying the BatchJob to be polled. max_poll_attempts: an int defining the number of times the BatchJob will be checked to determine whether it has...
examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py
def GetBatchJobDownloadUrlWhenReady(client, batch_job_id, max_poll_attempts=MAX_POLL_ATTEMPTS): """Retrieves the downloadUrl when the BatchJob is complete. Args: client: an instantiated AdWordsClient used to poll the BatchJob. batch_job_id: a long identifying the BatchJo...
def GetBatchJobDownloadUrlWhenReady(client, batch_job_id, max_poll_attempts=MAX_POLL_ATTEMPTS): """Retrieves the downloadUrl when the BatchJob is complete. Args: client: an instantiated AdWordsClient used to poll the BatchJob. batch_job_id: a long identifying the BatchJo...
[ "Retrieves", "the", "downloadUrl", "when", "the", "BatchJob", "is", "complete", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py#L188-L229
[ "def", "GetBatchJobDownloadUrlWhenReady", "(", "client", ",", "batch_job_id", ",", "max_poll_attempts", "=", "MAX_POLL_ATTEMPTS", ")", ":", "batch_job", "=", "GetBatchJob", "(", "client", ",", "batch_job_id", ")", "if", "batch_job", "[", "'status'", "]", "==", "'C...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
PrintResponse
Prints the BatchJobService response. Args: batch_job_helper: a BatchJobHelper instance. response_xml: a string containing a response from the BatchJobService.
examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py
def PrintResponse(batch_job_helper, response_xml): """Prints the BatchJobService response. Args: batch_job_helper: a BatchJobHelper instance. response_xml: a string containing a response from the BatchJobService. """ response = batch_job_helper.ParseResponse(response_xml) if 'rval' in response['muta...
def PrintResponse(batch_job_helper, response_xml): """Prints the BatchJobService response. Args: batch_job_helper: a BatchJobHelper instance. response_xml: a string containing a response from the BatchJobService. """ response = batch_job_helper.ParseResponse(response_xml) if 'rval' in response['muta...
[ "Prints", "the", "BatchJobService", "response", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/campaign_management/add_keywords_using_incremental_batch_job.py#L232-L251
[ "def", "PrintResponse", "(", "batch_job_helper", ",", "response_xml", ")", ":", "response", "=", "batch_job_helper", ".", "ParseResponse", "(", "response_xml", ")", "if", "'rval'", "in", "response", "[", "'mutateResponse'", "]", ":", "for", "data", "in", "respon...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.AddAdGroup
Create a new ad group. Args: client_customer_id: str Client Customer Id used to create the AdGroup. campaign_id: str Id of the campaign to use. name: str Name to assign to the AdGroup. status: str Status to assign to the AdGroup when it is created.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def AddAdGroup(self, client_customer_id, campaign_id, name, status): """Create a new ad group. Args: client_customer_id: str Client Customer Id used to create the AdGroup. campaign_id: str Id of the campaign to use. name: str Name to assign to the AdGroup. status: str Status to assign t...
def AddAdGroup(self, client_customer_id, campaign_id, name, status): """Create a new ad group. Args: client_customer_id: str Client Customer Id used to create the AdGroup. campaign_id: str Id of the campaign to use. name: str Name to assign to the AdGroup. status: str Status to assign t...
[ "Create", "a", "new", "ad", "group", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L52-L72
[ "def", "AddAdGroup", "(", "self", ",", "client_customer_id", ",", "campaign_id", ",", "name", ",", "status", ")", ":", "self", ".", "client", ".", "SetClientCustomerId", "(", "client_customer_id", ")", "ad_group_service", "=", "self", ".", "client", ".", "GetS...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.AddBudget
Create a new Budget with the given microAmount. Args: client_customer_id: str Client Customer Id used to create Budget. micro_amount: str The budget represented in micros. Returns: str BudgetId of the newly created Budget.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def AddBudget(self, client_customer_id, micro_amount): """Create a new Budget with the given microAmount. Args: client_customer_id: str Client Customer Id used to create Budget. micro_amount: str The budget represented in micros. Returns: str BudgetId of the newly created Budget. """...
def AddBudget(self, client_customer_id, micro_amount): """Create a new Budget with the given microAmount. Args: client_customer_id: str Client Customer Id used to create Budget. micro_amount: str The budget represented in micros. Returns: str BudgetId of the newly created Budget. """...
[ "Create", "a", "new", "Budget", "with", "the", "given", "microAmount", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L74-L99
[ "def", "AddBudget", "(", "self", ",", "client_customer_id", ",", "micro_amount", ")", ":", "self", ".", "client", ".", "SetClientCustomerId", "(", "client_customer_id", ")", "budget_service", "=", "self", ".", "client", ".", "GetService", "(", "'BudgetService'", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.AddCampaign
Add a Campaign to the client account. Args: client_customer_id: str Client Customer Id to use when creating Campaign. campaign_name: str Name of the campaign to be added. ad_channel_type: str Primary serving target the campaign's ads. budget: str a budget amount (in micros) to use.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def AddCampaign(self, client_customer_id, campaign_name, ad_channel_type, budget): """Add a Campaign to the client account. Args: client_customer_id: str Client Customer Id to use when creating Campaign. campaign_name: str Name of the campaign to be added. ad_channel_type: s...
def AddCampaign(self, client_customer_id, campaign_name, ad_channel_type, budget): """Add a Campaign to the client account. Args: client_customer_id: str Client Customer Id to use when creating Campaign. campaign_name: str Name of the campaign to be added. ad_channel_type: s...
[ "Add", "a", "Campaign", "to", "the", "client", "account", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L101-L134
[ "def", "AddCampaign", "(", "self", ",", "client_customer_id", ",", "campaign_name", ",", "ad_channel_type", ",", "budget", ")", ":", "self", ".", "client", ".", "SetClientCustomerId", "(", "client_customer_id", ")", "campaign_service", "=", "self", ".", "client", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.GetAccounts
Return the client accounts associated with the user's manager account. Returns: list List of ManagedCustomer data objects.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def GetAccounts(self): """Return the client accounts associated with the user's manager account. Returns: list List of ManagedCustomer data objects. """ selector = { 'fields': ['CustomerId', 'CanManageClients'] } accounts = self.client.GetService('ManagedCustomerService').get(sel...
def GetAccounts(self): """Return the client accounts associated with the user's manager account. Returns: list List of ManagedCustomer data objects. """ selector = { 'fields': ['CustomerId', 'CanManageClients'] } accounts = self.client.GetService('ManagedCustomerService').get(sel...
[ "Return", "the", "client", "accounts", "associated", "with", "the", "user", "s", "manager", "account", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L136-L148
[ "def", "GetAccounts", "(", "self", ")", ":", "selector", "=", "{", "'fields'", ":", "[", "'CustomerId'", ",", "'CanManageClients'", "]", "}", "accounts", "=", "self", ".", "client", ".", "GetService", "(", "'ManagedCustomerService'", ")", ".", "get", "(", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.GetAdGroups
Retrieves all AdGroups for the given campaign that haven't been removed. Args: client_customer_id: str Client Customer Id being used in API request. campaign_id: str id of the campaign for which to fetch ad groups. Returns: list List of AdGroup data objects.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def GetAdGroups(self, client_customer_id, campaign_id): """Retrieves all AdGroups for the given campaign that haven't been removed. Args: client_customer_id: str Client Customer Id being used in API request. campaign_id: str id of the campaign for which to fetch ad groups. Returns: list ...
def GetAdGroups(self, client_customer_id, campaign_id): """Retrieves all AdGroups for the given campaign that haven't been removed. Args: client_customer_id: str Client Customer Id being used in API request. campaign_id: str id of the campaign for which to fetch ad groups. Returns: list ...
[ "Retrieves", "all", "AdGroups", "for", "the", "given", "campaign", "that", "haven", "t", "been", "removed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L150-L181
[ "def", "GetAdGroups", "(", "self", ",", "client_customer_id", ",", "campaign_id", ")", ":", "self", ".", "client", ".", "SetClientCustomerId", "(", "client_customer_id", ")", "selector", "=", "{", "'fields'", ":", "[", "'Id'", ",", "'Name'", ",", "'Status'", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.GetBudget
Return a Budget with the associated budgetId. Args: client_customer_id: str Client Customer Id to which the budget belongs. budget_id: str id of the budget we want to examine. Returns: Budget A Budget data object.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def GetBudget(self, client_customer_id, budget_id): """Return a Budget with the associated budgetId. Args: client_customer_id: str Client Customer Id to which the budget belongs. budget_id: str id of the budget we want to examine. Returns: Budget A Budget data object. """ self.cl...
def GetBudget(self, client_customer_id, budget_id): """Return a Budget with the associated budgetId. Args: client_customer_id: str Client Customer Id to which the budget belongs. budget_id: str id of the budget we want to examine. Returns: Budget A Budget data object. """ self.cl...
[ "Return", "a", "Budget", "with", "the", "associated", "budgetId", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L183-L211
[ "def", "GetBudget", "(", "self", ",", "client_customer_id", ",", "budget_id", ")", ":", "self", ".", "client", ".", "SetClientCustomerId", "(", "client_customer_id", ")", "selector", "=", "{", "'fields'", ":", "[", "'BudgetId'", ",", "'BudgetName'", ",", "'Bud...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.GetCampaigns
Returns a client account's Campaigns that haven't been removed. Args: client_customer_id: str Client Customer Id used to retrieve Campaigns. Returns: list List of Campaign data objects.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def GetCampaigns(self, client_customer_id): """Returns a client account's Campaigns that haven't been removed. Args: client_customer_id: str Client Customer Id used to retrieve Campaigns. Returns: list List of Campaign data objects. """ self.client.SetClientCustomerId(client_customer_i...
def GetCampaigns(self, client_customer_id): """Returns a client account's Campaigns that haven't been removed. Args: client_customer_id: str Client Customer Id used to retrieve Campaigns. Returns: list List of Campaign data objects. """ self.client.SetClientCustomerId(client_customer_i...
[ "Returns", "a", "client", "account", "s", "Campaigns", "that", "haven", "t", "been", "removed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L213-L252
[ "def", "GetCampaigns", "(", "self", ",", "client_customer_id", ")", ":", "self", ".", "client", ".", "SetClientCustomerId", "(", "client_customer_id", ")", "# A somewhat hackish workaround for \"The read operation timed out\" error,", "# which could be triggered on AppEngine's end ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
APIHandler.UpdateBudget
Update a Budget with the given budgetId. Args: client_customer_id: str Client Customer Id used to update Budget. budget_id: str Id of the budget to be updated. micro_amount: str New value for the microAmount field. delivery_method: str New value for the deliveryMethod field.
examples/adwords/adwords_appengine_demo/handlers/api_handler.py
def UpdateBudget(self, client_customer_id, budget_id, micro_amount, delivery_method): """Update a Budget with the given budgetId. Args: client_customer_id: str Client Customer Id used to update Budget. budget_id: str Id of the budget to be updated. micro_amount: str New val...
def UpdateBudget(self, client_customer_id, budget_id, micro_amount, delivery_method): """Update a Budget with the given budgetId. Args: client_customer_id: str Client Customer Id used to update Budget. budget_id: str Id of the budget to be updated. micro_amount: str New val...
[ "Update", "a", "Budget", "with", "the", "given", "budgetId", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/adwords_appengine_demo/handlers/api_handler.py#L254-L275
[ "def", "UpdateBudget", "(", "self", ",", "client_customer_id", ",", "budget_id", ",", "micro_amount", ",", "delivery_method", ")", ":", "self", ".", "client", ".", "SetClientCustomerId", "(", "client_customer_id", ")", "operations", "=", "[", "{", "'operator'", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CreateExtensionSetting
Creates the extension setting for a list of Feed Items. Args: client: an AdWordsClient instance. feed_items: the list of all Feed Items. campaign_feed: the original Campaign Feed. feed_item_ids: the Ids of the feed items for which extension settings should be created. platform_restriction...
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def CreateExtensionSetting(client, feed_items, campaign_feed, feed_item_ids, platform_restrictions=None): """Creates the extension setting for a list of Feed Items. Args: client: an AdWordsClient instance. feed_items: the list of all Feed Items. campaign_feed: the original Ca...
def CreateExtensionSetting(client, feed_items, campaign_feed, feed_item_ids, platform_restrictions=None): """Creates the extension setting for a list of Feed Items. Args: client: an AdWordsClient instance. feed_items: the list of all Feed Items. campaign_feed: the original Ca...
[ "Creates", "the", "extension", "setting", "for", "a", "list", "of", "Feed", "Items", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L61-L98
[ "def", "CreateExtensionSetting", "(", "client", ",", "feed_items", ",", "campaign_feed", ",", "feed_item_ids", ",", "platform_restrictions", "=", "None", ")", ":", "campaign_extension_setting_service", "=", "client", ".", "GetService", "(", "'CampaignExtensionSettingServi...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
CreateSitelinkFeedItem
Creates a Sitelink Feed Item. Args: feed_items: a list of all Feed Items. feed_item_id: the Id of a specific Feed Item for which a Sitelink Feed Item should be created. Returns: The new Sitelink Feed Item.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def CreateSitelinkFeedItem(feed_items, feed_item_id): """Creates a Sitelink Feed Item. Args: feed_items: a list of all Feed Items. feed_item_id: the Id of a specific Feed Item for which a Sitelink Feed Item should be created. Returns: The new Sitelink Feed Item. """ site_link_from_feed =...
def CreateSitelinkFeedItem(feed_items, feed_item_id): """Creates a Sitelink Feed Item. Args: feed_items: a list of all Feed Items. feed_item_id: the Id of a specific Feed Item for which a Sitelink Feed Item should be created. Returns: The new Sitelink Feed Item. """ site_link_from_feed =...
[ "Creates", "a", "Sitelink", "Feed", "Item", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L101-L134
[ "def", "CreateSitelinkFeedItem", "(", "feed_items", ",", "feed_item_id", ")", ":", "site_link_from_feed", "=", "feed_items", "[", "feed_item_id", "]", "site_link_feed_item", "=", "{", "'sitelinkText'", ":", "site_link_from_feed", "[", "'text'", "]", ",", "'sitelinkLin...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DeleteCampaignFeed
Deletes a campaign feed. Args: client: an AdWordsClient instance. campaign_feed: the campaign feed to delete.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def DeleteCampaignFeed(client, campaign_feed): """Deletes a campaign feed. Args: client: an AdWordsClient instance. campaign_feed: the campaign feed to delete. """ campaign_feed_service = client.GetService('CampaignFeedService', 'v201809') operation = { 'operand': campaign_feed, 'operato...
def DeleteCampaignFeed(client, campaign_feed): """Deletes a campaign feed. Args: client: an AdWordsClient instance. campaign_feed: the campaign feed to delete. """ campaign_feed_service = client.GetService('CampaignFeedService', 'v201809') operation = { 'operand': campaign_feed, 'operato...
[ "Deletes", "a", "campaign", "feed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L137-L151
[ "def", "DeleteCampaignFeed", "(", "client", ",", "campaign_feed", ")", ":", "campaign_feed_service", "=", "client", ".", "GetService", "(", "'CampaignFeedService'", ",", "'v201809'", ")", "operation", "=", "{", "'operand'", ":", "campaign_feed", ",", "'operator'", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
DeleteOldFeedItems
Deletes the old feed items for which extension settings have been created. Args: client: an AdWordsClient instance. feed_item_ids: a list of Feed Item Ids. feed: the Feed containing the given Feed Item Ids.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def DeleteOldFeedItems(client, feed_item_ids, feed): """Deletes the old feed items for which extension settings have been created. Args: client: an AdWordsClient instance. feed_item_ids: a list of Feed Item Ids. feed: the Feed containing the given Feed Item Ids. """ if not feed_item_ids: return...
def DeleteOldFeedItems(client, feed_item_ids, feed): """Deletes the old feed items for which extension settings have been created. Args: client: an AdWordsClient instance. feed_item_ids: a list of Feed Item Ids. feed: the Feed containing the given Feed Item Ids. """ if not feed_item_ids: return...
[ "Deletes", "the", "old", "feed", "items", "for", "which", "extension", "settings", "have", "been", "created", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L154-L175
[ "def", "DeleteOldFeedItems", "(", "client", ",", "feed_item_ids", ",", "feed", ")", ":", "if", "not", "feed_item_ids", ":", "return", "feed_item_service", "=", "client", ".", "GetService", "(", "'FeedItemService'", ",", "'v201809'", ")", "operations", "=", "[", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetCampaignFeeds
Get a list of Feed Item Ids used by a campaign via a given Campaign Feed. Args: client: an AdWordsClient instance. feed: a Campaign Feed. placeholder_type: the Placeholder Type. Returns: A list of Feed Item Ids.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def GetCampaignFeeds(client, feed, placeholder_type): """Get a list of Feed Item Ids used by a campaign via a given Campaign Feed. Args: client: an AdWordsClient instance. feed: a Campaign Feed. placeholder_type: the Placeholder Type. Returns: A list of Feed Item Ids. """ campaign_feed_servi...
def GetCampaignFeeds(client, feed, placeholder_type): """Get a list of Feed Item Ids used by a campaign via a given Campaign Feed. Args: client: an AdWordsClient instance. feed: a Campaign Feed. placeholder_type: the Placeholder Type. Returns: A list of Feed Item Ids. """ campaign_feed_servi...
[ "Get", "a", "list", "of", "Feed", "Item", "Ids", "used", "by", "a", "campaign", "via", "a", "given", "Campaign", "Feed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L178-L228
[ "def", "GetCampaignFeeds", "(", "client", ",", "feed", ",", "placeholder_type", ")", ":", "campaign_feed_service", "=", "client", ".", "GetService", "(", "'CampaignFeedService'", ",", "'v201809'", ")", "campaign_feeds", "=", "[", "]", "more_pages", "=", "True", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetFeeds
Returns a list of all enabled Feeds. Args: client: an AdWordsClient instance. Returns: A list containing all enabled Feeds.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def GetFeeds(client): """Returns a list of all enabled Feeds. Args: client: an AdWordsClient instance. Returns: A list containing all enabled Feeds. """ feed_service = client.GetService('FeedService', 'v201809') feeds = [] more_pages = True selector = { 'fields': ['Id', 'Name', 'Attrib...
def GetFeeds(client): """Returns a list of all enabled Feeds. Args: client: an AdWordsClient instance. Returns: A list containing all enabled Feeds. """ feed_service = client.GetService('FeedService', 'v201809') feeds = [] more_pages = True selector = { 'fields': ['Id', 'Name', 'Attrib...
[ "Returns", "a", "list", "of", "all", "enabled", "Feeds", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L231-L274
[ "def", "GetFeeds", "(", "client", ")", ":", "feed_service", "=", "client", ".", "GetService", "(", "'FeedService'", ",", "'v201809'", ")", "feeds", "=", "[", "]", "more_pages", "=", "True", "selector", "=", "{", "'fields'", ":", "[", "'Id'", ",", "'Name'...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetFeedItems
Returns the Feed Items for a given Feed. Args: client: an AdWordsClient instance. feed: the Feed we are retrieving Feed Items from. Returns: The Feed Items associated with the given Feed.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def GetFeedItems(client, feed): """Returns the Feed Items for a given Feed. Args: client: an AdWordsClient instance. feed: the Feed we are retrieving Feed Items from. Returns: The Feed Items associated with the given Feed. """ feed_item_service = client.GetService('FeedItemService', 'v201809') ...
def GetFeedItems(client, feed): """Returns the Feed Items for a given Feed. Args: client: an AdWordsClient instance. feed: the Feed we are retrieving Feed Items from. Returns: The Feed Items associated with the given Feed. """ feed_item_service = client.GetService('FeedItemService', 'v201809') ...
[ "Returns", "the", "Feed", "Items", "for", "a", "given", "Feed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L277-L321
[ "def", "GetFeedItems", "(", "client", ",", "feed", ")", ":", "feed_item_service", "=", "client", ".", "GetService", "(", "'FeedItemService'", ",", "'v201809'", ")", "feed_items", "=", "[", "]", "more_pages", "=", "True", "selector", "=", "{", "'fields'", ":"...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetFeedItemIdsForCampaign
Gets the Feed Item Ids used by a campaign through a given Campaign Feed. Args: campaign_feed: the Campaign Feed we are retrieving Feed Item Ids from. Returns: A list of Feed Item IDs.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def GetFeedItemIdsForCampaign(campaign_feed): """Gets the Feed Item Ids used by a campaign through a given Campaign Feed. Args: campaign_feed: the Campaign Feed we are retrieving Feed Item Ids from. Returns: A list of Feed Item IDs. """ feed_item_ids = set() try: lhs_operand = campaign_feed['...
def GetFeedItemIdsForCampaign(campaign_feed): """Gets the Feed Item Ids used by a campaign through a given Campaign Feed. Args: campaign_feed: the Campaign Feed we are retrieving Feed Item Ids from. Returns: A list of Feed Item IDs. """ feed_item_ids = set() try: lhs_operand = campaign_feed['...
[ "Gets", "the", "Feed", "Item", "Ids", "used", "by", "a", "campaign", "through", "a", "given", "Campaign", "Feed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L324-L350
[ "def", "GetFeedItemIdsForCampaign", "(", "campaign_feed", ")", ":", "feed_item_ids", "=", "set", "(", ")", "try", ":", "lhs_operand", "=", "campaign_feed", "[", "'matchingFunction'", "]", "[", "'lhsOperand'", "]", "except", "KeyError", ":", "lhs_operand", "=", "...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetFeedMapping
Gets the Feed Mapping for a given Feed. Args: client: an AdWordsClient instance. feed: the Feed we are retrieving the Feed Mapping for. placeholder_type: the Placeholder Type we are looking for. Returns: A dictionary containing the Feed Mapping.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def GetFeedMapping(client, feed, placeholder_type): """Gets the Feed Mapping for a given Feed. Args: client: an AdWordsClient instance. feed: the Feed we are retrieving the Feed Mapping for. placeholder_type: the Placeholder Type we are looking for. Returns: A dictionary containing the Feed Mappi...
def GetFeedMapping(client, feed, placeholder_type): """Gets the Feed Mapping for a given Feed. Args: client: an AdWordsClient instance. feed: the Feed we are retrieving the Feed Mapping for. placeholder_type: the Placeholder Type we are looking for. Returns: A dictionary containing the Feed Mappi...
[ "Gets", "the", "Feed", "Mapping", "for", "a", "given", "Feed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L353-L408
[ "def", "GetFeedMapping", "(", "client", ",", "feed", ",", "placeholder_type", ")", ":", "feed_mapping_service", "=", "client", ".", "GetService", "(", "'FeedMappingService'", ",", "'v201809'", ")", "attribute_mappings", "=", "{", "}", "more_pages", "=", "True", ...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874
train
GetPlatformRestrictions
Get the Platform Restrictions for a given Campaign Feed. Args: campaign_feed: the Campaign Feed we are retrieving Platform Restrictons for. Returns: The Platform Restrictions for the given feed.
examples/adwords/v201809/migration/migrate_to_extension_settings.py
def GetPlatformRestrictions(campaign_feed): """Get the Platform Restrictions for a given Campaign Feed. Args: campaign_feed: the Campaign Feed we are retrieving Platform Restrictons for. Returns: The Platform Restrictions for the given feed. """ platform_restrictions = None if campaign_feed['matc...
def GetPlatformRestrictions(campaign_feed): """Get the Platform Restrictions for a given Campaign Feed. Args: campaign_feed: the Campaign Feed we are retrieving Platform Restrictons for. Returns: The Platform Restrictions for the given feed. """ platform_restrictions = None if campaign_feed['matc...
[ "Get", "the", "Platform", "Restrictions", "for", "a", "given", "Campaign", "Feed", "." ]
googleads/googleads-python-lib
python
https://github.com/googleads/googleads-python-lib/blob/aa3b1b474b0f9789ca55ca46f4b2b57aeae38874/examples/adwords/v201809/migration/migrate_to_extension_settings.py#L411-L433
[ "def", "GetPlatformRestrictions", "(", "campaign_feed", ")", ":", "platform_restrictions", "=", "None", "if", "campaign_feed", "[", "'matchingFunction'", "]", "[", "'operator'", "]", "==", "'AND'", ":", "for", "argument", "in", "campaign_feed", "[", "'matchingFuncti...
aa3b1b474b0f9789ca55ca46f4b2b57aeae38874