How to get the number of conversions by each conversion action by query

53 views
Skip to first unread message

Riku Kudo

unread,
Jun 27, 2024, 8:05:56 PM6/27/24
to Google Ads API and AdWords API Forum
Hello.

I want to get the number of conversions by each conversion action by query.

I have assembled such a query for this purpose, but it does not work.

=======================================
SELECT CampaignName,
 AdGroupName,
 Query,
 metrics.all_conversions,
 Conversions.購入,
 Conversions.購入確認,
 Conversions.フォーム遷移(化粧品)
 FROM SEARCH_QUERY_PERFORMANCE_REPORT
 WHERE Conversions > 0 DURING 2023-12-01,2024-05-31
=======================================

「購入」「購入確認」「フォーム遷移(化粧品)」 are the names of conversion actions for which the number of conversions is to be obtained, respectively.
How should the above be modified?

Thanks.

Google Ads API Forum Advisor

unread,
Jun 28, 2024, 12:57:09 AM6/28/24
to r.k...@lifunext.com, adwor...@googlegroups.com
Hi,

Thank you for reaching out to the Google Ads API support team.

Based on the information provided, I understand that you are looking for guidance to get the number of conversions by each conversion action by query. I would recommend you to use the conversion_action resource to obtain the number of conversions for each conversion action from the Google Ads API. Please find the sample GAQL query as per your requirement:
SELECT conversion_action.id, conversion_action.name, metrics.all_conversions, 
metrics.all_conversions_value, conversion_action.resource_name, segments.date FROM 
conversion_action WHERE segments.date BETWEEN '2023-12-01' AND '2024-05-31' AND 
conversion_action.id = {conversion_action_ID}
You can use the search or searchStream methods to execute this GAQL query from the Google Ads API. Similarly for each conversion action you need to change the ID and execute this query to obtain the results for all the conversion action IDs. Additionally, you can utilize the Google Ads Query Builder and Query Validator to build and validate the queries for retrieving the data from the Google Ads API.
 
This message is in relation to case "ref:!00D1U01174p.!5004Q02tJVRH:ref" (ADR-00244445)

Thanks,

 
Google Logo Google Ads API Team

Register for the upcoming workshop: Performance Max and the Google Ads API!
 


Reply all
Reply to author
Forward
0 new messages