Hello Matt,

Here is the code we use:
query = '''SELECT 
segments.date,campaign.name,ad_group.name,ad_group_ad.ad.type,metrics.impressions
 
from ad_group_ad WHERE segments.date DURING YESTERDAY'''
search_request = googleads_client.get_type("SearchGoogleAdsStreamRequest")
search_request.customer_id = 'xxxxxxxxxx'
search_request.query = query
response = ga_service.search_stream(search_request)
for batch in response:
    for row in batch.results:
           print(row.ad_group_ad.ad.type_)


Thank you.

On Wednesday, June 2, 2021 at 11:00:05 PM UTC+5:30 adsapiforumadvisor wrote:

> Hello,
>
> Thanks for reaching out. Can you please clarify how you are retrieving the 
> enum ordinal for the ad type in the Ads API? 
>
> Thanks,
> Matt
> Google Ads API Team
>
> [image: Google Logo] 
> Matt 
> Google Ads API Team 
>   
>
> ref:_00D1U1174p._5004Q2HzWQD:ref
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/b7425a78-a711-4c22-a69c-a71492a85952n%40googlegroups.com.

Reply via email to