Hi,
Trying to fetch the average_cpc_micros value for keywords but always get a null value even after activating the include_average_cpc as below (even though the low_top_of_page_bid_micros and high_top_of_page_bid_micros have values in them).
Have I missed something to fetch it ?
$generateHistoricalMetrics = $keywordPlanServiceClient->generateHistoricalMetrics(
ResourceNames::forKeywordPlan($customerId, $keywordPlanId),
[
'historicalMetricsOptions' => new HistoricalMetricsOptions(
['include_average_cpc' => true]
)
]
);
foreach ($generateHistoricalMetrics->getMetrics() as $historical) {
$metrics = $historical->getKeywordMetrics();
\Log::info("avg : " . $metrics->getAverageCpcMicros() / 1000000);
}
I've installed the latest V15.0 version.
Thx