Hello everyone,
I have exactly the *same problem* as you. I am using
*GoogleAdsService.Search* to retrieve the information about ImageAd and its
associated MediaFile. To achieve this, I would need to get the MediaFile
ResourceName, but that´s a field that is not available to SELECT clauses.
Here is an example of my query:
SELECT
ad_group.id,
campaign.id,
ad_group_ad.policy_summary.policy_topic_entries,
ad_group_ad.policy_summary.review_status,
ad_group_ad.policy_summary.approval_status,
ad_group_ad.status,
ad_group_ad.ad.id,
ad_group_ad.ad.final_urls,
ad_group_ad.ad.name,
ad_group_ad.ad.image_ad.image_url,
ad_group_ad.ad.image_ad.name,
ad_group_ad.ad.image_ad.media_file -> The following
field may not be used in SELECT clause, but I need it!!! :_(
FROM ad_group_ad
Have you found any solution?
Thank you very much! Greetings from Spain
El miércoles, 26 de enero de 2022 a las 1:54:51 UTC+1, [email protected]
escribió:
> Hi,
>
> I am currently working on migrating our AdWords API client to GoogleAds
> API client, and I am having an issue to list all ImageAds with the
> GoogleAdsService.Search (Google Ads SearchQuery).
>
> In the old AdWords API, the AdGroupAdService.Get() will return an ImageAd
> with Image entity (
> https://developers.google.com/adwords/api/docs/reference/v201809/AdGroupAdService.ImageAd)
>
> (
> https://developers.google.com/adwords/api/docs/reference/v201809/AdGroupAdService.Image
> )
> The Image entity contains all media file info,
>
>
> With AdGroupAdService.Get(), I can get an AdGroupAd with ImageAdInfo, (
> https://developers.google.com/google-ads/api/reference/rpc/v9/ImageAdInfo?hl=en)
>
> and it would contains either a "media_file" filed (media file resourceName)
> or "data" field (Raw image data as bytes).
>
> But when I try to list ImageAds with the GoogleAdsService.Search (Google
> Ads SearchQuery). I can only find those ImageAd fields available for
> query:
>
> - ad_group_ad.ad.image_ad.image_url
> - ad_group_ad.ad.image_ad.mime_type
> - ad_group_ad.ad.image_ad.name
> - ad_group_ad.ad.image_ad.pixel_height
> - ad_group_ad.ad.image_ad.pixel_width
> - ad_group_ad.ad.image_ad.preview_image_url
> - ad_group_ad.ad.image_ad.preview_pixel_height
> - ad_group_ad.ad.image_ad.preview_pixel_width
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> I could not get the MediaFile Resource Name of the image or the raw data.
>
> May I ask is there a way to list ImageAd with the media file info by
> search query? or is there another option to link them?
>
>
> BTWI found for VideoAd, the search query actually provided a filed called
> "ad_group_ad.ad.video_ad.media_file" and it contains the Video Media file
> resource name. If I can get the MediaFile Resource Name as field
> "ad_group_ad.ad.image_ad.media_file", I might be able to make another query
> from media_file to get the media file detailed info.
>
>
> Thanks!
>
>
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 [email protected]
To unsubscribe from this group, send email to
[email protected]
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
"Google Ads API and AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/adwords-api/db781834-c304-41a1-9829-36393d071af8n%40googlegroups.com.