คุณสามารถดึงแอตทริบิวต์การรายงานและเมตริกประสิทธิภาพสําหรับแคมเปญ Demand Gen ได้ที่ระดับแคมเปญ โฆษณา และชิ้นงาน
การรายงานระดับแคมเปญ
คุณสามารถใช้ GoogleAdsService.SearchStream เพื่อดึงข้อมูลแอตทริบิวต์และเมตริกประสิทธิภาพสําหรับแคมเปญ Demand Gen ได้เช่นเดียวกับแคมเปญประเภทอื่นๆ
SELECT
campaign.id,
campaign.status,
campaign.bidding_strategy_type,
metrics.impressions,
metrics.clicks,
metrics.cost_micros
FROM campaign
WHERE campaign.advertising_channel_type = DEMAND_GEN
หากต้องการแบ่งกลุ่มคลิกในการรายงานสําหรับแคมเปญ Demand Gen ตามประเภทการคลิก ให้กรองตามsegments.click_type = CROSS_NETWORK:
SELECT
campaign.id,
segments.click_type,
metrics.clicks
FROM campaign
WHERE campaign.advertising_channel_type = DEMAND_GEN
AND segments.click_type = CROSS_NETWORK
หากต้องการแจกแจงประสิทธิภาพของ Demand Gen ตามช่องทาง (เช่น YOUTUBE, DISCOVER, GMAIL, MAPS หรือ CONTENT) และแพลตฟอร์ม YouTube (YOUTUBE_INSTREAM, YOUTUBE_INFEED, YOUTUBE_SHORTS หรือ UNSEGMENTED) ให้เลือกทั้ง segments.ad_network_type และ segments.ad_sub_network_type (โปรดทราบว่าต้องเลือก segments.ad_sub_network_type พร้อมกับ segments.ad_network_type เสมอ)
SELECT
campaign.id,
segments.ad_network_type,
segments.ad_sub_network_type,
metrics.impressions,
metrics.clicks,
metrics.cost_micros,
metrics.video_trueview_views
FROM campaign
WHERE campaign.advertising_channel_type = DEMAND_GEN
การรายงานระดับโฆษณา
Google Ads API รองรับโฆษณา Demand Gen แบบหลายชิ้นงาน, ภาพสไลด์, วิดีโอที่ปรับเปลี่ยนตามอุปกรณ์ และโฆษณาสินค้า (DemandGenMultiAssetAdInfo, DemandGenCarouselAdInfo, DemandGenVideoResponsiveAdInfo และ DemandGenProductAdInfo) ใช้คำค้นหาเหล่านี้กับ GoogleAdsService.SearchStream เพื่อดึงแอตทริบิวต์และเมตริกของโฆษณา
SELECT
ad_group_ad.ad.id,
ad_group_ad.ad.type,
ad_group_ad.ad.demand_gen_multi_asset_ad.marketing_images,
ad_group_ad.ad.demand_gen_multi_asset_ad.square_marketing_images,
ad_group_ad.ad.demand_gen_multi_asset_ad.portrait_marketing_images,
ad_group_ad.ad.demand_gen_multi_asset_ad.tall_portrait_marketing_images,
ad_group_ad.ad.demand_gen_multi_asset_ad.classic_display_images,
ad_group_ad.ad.demand_gen_multi_asset_ad.logo_images,
ad_group_ad.ad.demand_gen_multi_asset_ad.headlines,
ad_group_ad.ad.demand_gen_multi_asset_ad.descriptions,
ad_group_ad.ad.demand_gen_multi_asset_ad.business_name,
ad_group_ad.ad.demand_gen_multi_asset_ad.call_to_action_text,
metrics.impressions,
metrics.clicks,
metrics.cost_micros
FROM ad_group_ad
WHERE ad_group_ad.ad.type = DEMAND_GEN_MULTI_ASSET_AD
SELECT
ad_group_ad.ad.id,
ad_group_ad.ad.type,
ad_group_ad.ad.demand_gen_carousel_ad.business_name,
ad_group_ad.ad.demand_gen_carousel_ad.logo_image,
ad_group_ad.ad.demand_gen_carousel_ad.headline,
ad_group_ad.ad.demand_gen_carousel_ad.description,
ad_group_ad.ad.demand_gen_carousel_ad.call_to_action_text,
ad_group_ad.ad.demand_gen_carousel_ad.carousel_cards,
metrics.impressions,
metrics.clicks,
metrics.cost_micros
FROM ad_group_ad
WHERE ad_group_ad.ad.type = DEMAND_GEN_CAROUSEL_AD
SELECT
ad_group_ad.ad.id,
ad_group_ad.ad.type,
ad_group_ad.ad.demand_gen_video_responsive_ad.breadcrumb1,
ad_group_ad.ad.demand_gen_video_responsive_ad.breadcrumb2,
ad_group_ad.ad.demand_gen_video_responsive_ad.business_name,
ad_group_ad.ad.demand_gen_video_responsive_ad.call_to_actions,
ad_group_ad.ad.demand_gen_video_responsive_ad.companion_banners,
ad_group_ad.ad.demand_gen_video_responsive_ad.descriptions,
ad_group_ad.ad.demand_gen_video_responsive_ad.headlines,
ad_group_ad.ad.demand_gen_video_responsive_ad.logo_images,
ad_group_ad.ad.demand_gen_video_responsive_ad.long_headlines,
ad_group_ad.ad.demand_gen_video_responsive_ad.videos,
metrics.impressions,
metrics.clicks,
metrics.cost_micros,
metrics.video_trueview_views
FROM ad_group_ad
WHERE ad_group_ad.ad.type = DEMAND_GEN_VIDEO_RESPONSIVE_AD
SELECT
ad_group_ad.ad.id,
ad_group_ad.ad.type,
ad_group_ad.ad.demand_gen_product_ad.headline,
ad_group_ad.ad.demand_gen_product_ad.description,
ad_group_ad.ad.demand_gen_product_ad.logo_image,
ad_group_ad.ad.demand_gen_product_ad.breadcrumb1,
ad_group_ad.ad.demand_gen_product_ad.breadcrumb2,
ad_group_ad.ad.demand_gen_product_ad.business_name,
ad_group_ad.ad.demand_gen_product_ad.call_to_action,
metrics.impressions,
metrics.clicks,
metrics.cost_micros
FROM ad_group_ad
WHERE ad_group_ad.ad.type = DEMAND_GEN_PRODUCT_AD
นอกจากนี้ คุณยังค้นหาโฆษณา Demand Gen ทุกประเภทพร้อมกันในคำขอเดียวได้ด้วย โดยทำดังนี้
SELECT
ad_group_ad.ad.id,
ad_group_ad.ad.type,
ad_group_ad.ad.demand_gen_multi_asset_ad.headlines,
ad_group_ad.ad.demand_gen_carousel_ad.headline,
ad_group_ad.ad.demand_gen_video_responsive_ad.headlines,
ad_group_ad.ad.demand_gen_product_ad.headline,
ad_group_ad.ad.demand_gen_product_ad.description,
ad_group_ad.ad.demand_gen_product_ad.business_name,
metrics.impressions,
metrics.clicks,
metrics.cost_micros
FROM ad_group_ad
WHERE ad_group_ad.ad.type IN (
DEMAND_GEN_MULTI_ASSET_AD,
DEMAND_GEN_CAROUSEL_AD,
DEMAND_GEN_VIDEO_RESPONSIVE_AD,
DEMAND_GEN_PRODUCT_AD
)
การรายงานระดับชิ้นงาน
แคมเปญ Demand Gen มีประเภทชิ้นงานเฉพาะสําหรับการ์ดภาพสไลด์ (DEMAND_GEN_CAROUSEL_CARD) ใช้ GoogleAdsService.SearchStream เพื่อดึงข้อมูลชิ้นงานเหล่านี้
SELECT
asset.id,
asset.demand_gen_carousel_card_asset.marketing_image_asset,
asset.demand_gen_carousel_card_asset.square_marketing_image_asset,
asset.demand_gen_carousel_card_asset.portrait_marketing_image_asset,
asset.demand_gen_carousel_card_asset.headline,
asset.demand_gen_carousel_card_asset.call_to_action_text
FROM asset
WHERE asset.type = DEMAND_GEN_CAROUSEL_CARD
นอกจากนี้ คุณยังเรียกข้อมูลเมตริกประสิทธิภาพของชิ้นงาน DEMAND_GEN_CAROUSEL_CARD โดยใช้ ad_group_ad_asset_view ได้ด้วย
SELECT
asset.id,
asset.name,
asset.type,
metrics.impressions
FROM ad_group_ad_asset_view
WHERE ad_group_ad_asset_view.field_type = DEMAND_GEN_CAROUSEL_CARD
เอนทิตีที่ไม่รองรับ
แม้ว่าระบบจะรองรับโฆษณาวิดีโอ Demand Gen มาตรฐานที่ปรับเปลี่ยนตามพื้นที่โฆษณา (DEMAND_GEN_VIDEO_RESPONSIVE_AD) แต่โฆษณาวิดีโอ Discovery เดิมที่เลิกใช้งานแล้วซึ่งแสดงใน UI ของ Google Ads ที่มีประเภทโฆษณาเป็น "โฆษณาวิดีโอ Demand Gen (เดิม)" ไม่ได้รับการรองรับจาก Google Ads API และจะไม่แสดงผลโดย GoogleAdsService.SearchStream หรือ GoogleAdsService.Search