API_requests rate sheet

189 views
Skip to first unread message

Harshad Khanapure

unread,
Oct 11, 2020, 5:11:35 AM10/11/20
to AdWords API and Google Ads API Forum
Hi,

1. I am trying to understand things on the following page


If I ran the following query 

query = """
    SELECT
      ad_group_criterion.cpc_bid_micros,
      ad_group_criterion.keyword.text,
      ad_group_criterion.keyword.match_type,
      ad_group_criterion_label.label,
      campaign.name


    FROM keyword_view
    
    WHERE ad_group_criterion.type = KEYWORD
    AND campaign.name= 'XXXXXXX XXX XXX'
    """

It returns 1,000,000+ keywords data. Does that mean it will be counted as 1 operation or 1,000,000+?



2. As it's mentioned in the above link that daily limit for operation is 10,000. If I try to execute code which performs more than 10,000 operations(mutate), 

A . will it show an error  stating - you can not perform more than 10000 operations and code will not be executed OR 

B. code will get executed and I will be charged for operations above 10,000


3. For following code

I am trying to change Max CPC of three keywords, will it be counted as 3 operations and I will be charged for three operations OR it will be treated as 1 operation

def bid_change(client, customer_id, ad_group_id, criterion_id,bid):
agc_service = client.get_service("AdGroupCriterionService", version="v5")


ad_group_criterion_operation = client.get_type(
"AdGroupCriterionOperation", version="v5"
)


ad_group_criterion = ad_group_criterion_operation.update
ad_group_criterion.resource_name = agc_service.ad_group_criteria_path(
customer_id, ResourceName.format_composite(ad_group_id, criterion_id)
)
#customers/{customer_id}/adGroupCriteria/{ad_group_id}~{criterion_id}
ad_group_criterion.cpc_bid_micros= bid
fm = protobuf_helpers.field_mask(None, ad_group_criterion)
ad_group_criterion_operation.update_mask.CopyFrom(fm)


try:
agc_response = agc_service.mutate_ad_group_criteria(
customer_id, [ad_group_criterion_operation]
)
except google.ads.google_ads.errors.GoogleAdsException as ex:
print(
'Request with ID "%s" failed with status "%s" and includes the '
"following errors:" % (ex.request_id, ex.error.code().name)
)
for error in ex.failure.errors:
print('\tError with message "%s".' % error.message)
if error.location:
for field_path_element in error.location.field_path_elements:
print("\t\tOn field: %s" % field_path_element.field_name)
sys.exit(1)


print("Updated keyword %s." % agc_response.results[0].resource_name)




Google Ads API Forum Advisor Prod

unread,
Oct 12, 2020, 2:16:20 AM10/12/20
to harshadk...@papertrue.com, adwor...@googlegroups.com
Hi Harshad,

Thanks for posting your concern.

Could you clarify first if your concern is related to Google Ads API or AdWords API? I asked this because the report you have specified in #1 item is for Google Ads API but the document you've provided is for AdWords API. If your concern is related to Google Ads API, then this is the document that you should referring.

For now, since your code and report is based on Google Ads API, let me provide support on Google Ads API perspective as well.

Please find my answer below for each question:
1. It returns 1,000,000+ keywords data. Does that mean it will be counted as 1 operation or 1,000,000+?
-
Reports would currently not be able to return 1,000,000 records at a time. Report sizes may be only up to 100,000 rows as discussed here.

As additional information, please note that if page_size is not specified, it is automatically set to the maximum page size of 10,000 rows as discussed here. Also, as discussed in our best concepts guide for retrieving objects, the recommendation would be to limit the number of objects returned.

You may check out our paging guide and the rest of our streaming guide for the best reporting options you can implement that would fit your requirement.


2. As it's mentioned in the above link that daily limit for operation is 10,000. If I try to execute code which performs more than 10,000 operations(mutate), 

-The daily operation limit for developer token with Basic access/Test account is 15,000 for Google Ads API. If you will perform more than 15,000 operations, then you will encounter the RESOURCE_EXHAUSTED quota error.


3. For following code
I am trying to change Max CPC of three keywords, will it be counted as 3 operations and I will be charged for three operations OR it will be treated as 1 operation

-This will count as 3 operations.

Let me know if you have further questions.

Regards,
Google Logo
Ernie John Blanca Tacata
Google Ads API Team
 


ref:_00D1U1174p._5004Q268PDJ:ref

Harshad Khanapure

unread,
Oct 13, 2020, 2:12:07 PM10/13/20
to AdWords API and Google Ads API Forum
Kindly explain question 1 by replacing 10,000,000 by 100,000 and 10,000. 

For your understanding question will be modified to this

1. for 100,000 keywords

1. I am trying to understand things on the following page


If I ran the following query 

query = """
    SELECT
      ad_group_criterion.cpc_bid_micros,
      ad_group_criterion.keyword.text,
      ad_group_criterion.keyword.match_type,
      ad_group_criterion_label.label,
      campaign.name


    FROM keyword_view
    
    WHERE ad_group_criterion.type = KEYWORD
    AND campaign.name= 'XXXXXXX XXX XXX'
    """

It returns 100,000 keywords data. Does that mean it will be counted as 1 operation or 100,000?


----------------------------------------------------------------------------------------------------------------------------------------

1. for 10,000 keywords

1. I am trying to understand things on the following page


If I ran the following query 

query = """
    SELECT
      ad_group_criterion.cpc_bid_micros,
      ad_group_criterion.keyword.text,
      ad_group_criterion.keyword.match_type,
      ad_group_criterion_label.label,
      campaign.name


    FROM keyword_view
    
    WHERE ad_group_criterion.type = KEYWORD
    AND campaign.name= 'XXXXXXX XXX XXX'
    """

It returns 10,000 keywords data. Does that mean it will be counted as 1 operation or 10,000?

Google Ads API Forum Advisor Prod

unread,
Oct 13, 2020, 10:37:43 PM10/13/20
to harshadk...@papertrue.com, adwor...@googlegroups.com
Hi Harshad,

Thanks for the reply.

Since you are using Google Ads API for the reporting, then you should refer to this Rate Sheet guide instead.

Moving forward, each report that you've specified will be counted as 1 operation. As for the 1 first report, paging will be applied or the result will break up and will return in multiple responses as describe on this document. However, you may note that when using paging, your query must remain exactly the same in subsequent requests to take advantage of the cached data; the requests won't contribute towards your quota, particularly for basic access.

Harshad Khanapure

unread,
Oct 13, 2020, 11:22:50 PM10/13/20
to Google Ads API Forum Advisor Prod, adwor...@googlegroups.com
My concern is not about the rate sheet, can you please let me know the answer using the rate sheet you mentioned? 

--
Harshad Khanapure 
Manager | Google Ads & PPC

Google Ads API Forum Advisor Prod

unread,
Oct 14, 2020, 10:55:18 AM10/14/20
to harshadk...@papertrue.com, adwor...@googlegroups.com
Hi Harshad,

These calls that you've mentioned will each count as one operation. 

Cheers,
Anthony
Google Ads API Team

Google Logo
Anthony
Google Ads API Team
 


ref:_00D1U1174p._5004Q268PDJ:ref

Harshad Khanapure

unread,
Oct 14, 2020, 12:35:32 PM10/14/20
to Google Ads API Forum Advisor Prod, adwor...@googlegroups.com
Can you be little specific and count of operations for the above two queries?

1 OR 5 OR 100,000/10,000?

Harshad Khanapure

unread,
Oct 14, 2020, 12:36:10 PM10/14/20
to Google Ads API Forum Advisor Prod, adwor...@googlegroups.com
Can you be little specific and let me know count of operations for the above two queries?

1 OR 5 OR 100,000/10,000?

Google Ads API Forum Advisor Prod

unread,
Oct 14, 2020, 3:57:13 PM10/14/20
to harshadk...@papertrue.com, adwor...@googlegroups.com
Hi Harshad,

For each query, it counts as one operation. The number of results that return will not affect the operation count.

Regards,

Harshad Khanapure

unread,
Oct 15, 2020, 7:52:40 AM10/15/20
to AdWords API and Google Ads API Forum
can please give me the numbers that I am asking not the explanation 

Google Ads API Forum Advisor Prod

unread,
Oct 15, 2020, 11:22:15 AM10/15/20
to harshadk...@papertrue.com, adwor...@googlegroups.com
Hi,


1. I am trying to understand things on the following page

https://developers.google.com/adwords/api/docs/ratesheet#api-operations

If I ran the following query 

query = """
    SELECT
      ad_group_criterion.cpc_bid_micros,
      ad_group_criterion.keyword.text,
      ad_group_criterion.keyword.match_type,
      ad_group_criterion_label.label,
      campaign.name


    FROM keyword_view
    
    WHERE ad_group_criterion.type = KEYWORD
    AND campaign.name= 'XXXXXXX XXX XXX'
    """

It returns 100,000 keywords data. Does that mean it will be counted as 1 operation or 100,000?
This is 1 operation.


1. for 10,000 keywords

1. I am trying to understand things on the following page

https://developers.google.com/adwords/api/docs/ratesheet#api-operations


If I ran the following query 

query = """
    SELECT
      ad_group_criterion.cpc_bid_micros,
      ad_group_criterion.keyword.text,
      ad_group_criterion.keyword.match_type,
      ad_group_criterion_label.label,
      campaign.name


    FROM keyword_view
    
    WHERE ad_group_criterion.type = KEYWORD
    AND campaign.name= 'XXXXXXX XXX XXX'
    """

It returns 10,000 keywords data. Does that mean it will be counted as 1 operation or 10,000?
This is 1 operation.

Harshad Khanapure

unread,
Oct 15, 2020, 12:41:59 PM10/15/20
to Google Ads API Forum Advisor Prod, adwor...@googlegroups.com
Thanks, Anthony 
Reply all
Reply to author
Forward
0 new messages