AdWords API is returning more CampaignCriterion/UserList than Google Ads APIPI

253 views
Skip to first unread message

Leo Sanchez

unread,
Mar 14, 2022, 7:05:32 PM3/14/22
to Google Ads API and AdWords API Forum
Hi,

As we are in the process of migrating away from AdWords API to Google Ads API we found a discrepancy in the data Google Ads API is returning for many clients regarding the CampaingCriterion, specifically the ones with type USER_LIST and the user_list that should be related to it.

For a particular client AdWords is returning 69 CampaignCriterion objects and all of them have the CriterionUserList object present. That'd be id, userListId, userListName, etc.
The same client but in Google Ads API has also 69 CampaignCriterion objects but only 65 have the CriterionUserList object present and the other 4 don't have a criterion at all.
This is a problem because our code is expecting the Google Ads API to have the same info as AdWords API and when doing a comparation between objects we don't know what info we should trust.

We are doing the following query in Google Ads API (I removed some fields to make it shorter and left only what I feel it's important):

Select campaign.id,
campaign_criterion.criterion_id,
campaign_criterion.type,  
campaign_criterion.user_list.user_list,
user_list.id,
user_list.name,
user_list.membership_status,
user_list.description
From campaign_criterion 
Where campaign.id = XXXXX AND campaign_criterion.type IN ('USER_LIST') AND campaign_criterion.status IN ('ENABLED')
ORDER BY campaign_criterion.criterion_id


This is good enough to get the info from the user_list table (since we can't really joing from it) and return it alongside the CampaignCriterion. As I mentioned this works for 65 objects, but 4 of them do have a campaign_criterion.user_list.user_list but no userl_list object.
I even queried the user_list table with a simple select for that specific customerId and it returned a lot of userList objects but not the ones I know are missing from the CampaignCriterion call I commented before.

Is there a specific or correct way to do the CampaignCriterion query to get all the info we need? Is there any filter I should add the tell the API that I want all the criterions from a CampaignCriterion no matter what is the status, name and such? I'm not sure what we're missing here.

Thanks in advance,
Leo



Google Ads API Forum Advisor

unread,
Mar 15, 2022, 10:31:45 AM3/15/22
to leosanche...@gmail.com, adwor...@googlegroups.com
Hi Leo,

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

Could you share with us the following details below so our team can better check on the issue?

You may then send the requested logs via the Reply privately to author option. If this option is not available, you may send the details directly to our googleadsa...@google.com alias instead.

Thanks,
Google Logo
Nirmita
Google Ads API Team
 


ref:_00D1U1174p._5004Q2YlJQf:ref

Leo Sanchez

unread,
Mar 16, 2022, 4:30:19 PM3/16/22
to Google Ads API and AdWords API Forum
Replied to Nirmita with the requested info.

Thanks,
Leo

Google Ads API Forum Advisor

unread,
Mar 17, 2022, 12:46:09 PM3/17/22
to leosanche...@gmail.com, adwor...@googlegroups.com
Hi Leo,

Thank you for providing information.

Please allow me to share this with our team and we will provide an update shortly.

Thanks,

Ngon Nguyen

unread,
Mar 17, 2022, 8:06:43 PM3/17/22
to leosanche...@gmail.com, Google Ads API and AdWords API Forum
Chào mừng bạn đến với bảng nhớ tạm của Gboard, bất kỳ văn bản nào bạn sao chép sẽ được lưu tại đây.Sử dụng biểu tượng chỉnh sửa để ghim, thêm hoặc xóa đoạn.Nhấn vào một đoạn để dán vào hộp văn bản.Chạm và giữ một đoạn để ghim đoạn đó. Các đoạn đã bỏ ghim sẽ bị xóa sau 1 giờ.

Vào 6:05, Th 3, 15 thg 3, 2022 Leo Sanchez <leosanche...@gmail.com> đã viết:
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 adwor...@googlegroups.com
To unsubscribe from this group, send email to
adwords-api...@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 "Google Ads API and AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/88195fab-cfb8-4082-a4af-b321fcfa17e2n%40googlegroups.com.

Google Ads API Forum Advisor

unread,
Mar 18, 2022, 5:51:53 AM3/18/22
to ngonng...@gmail.com, leosanche...@gmail.com, adwor...@googlegroups.com

Hi Leo,

I have tried to impersonate your reports on my end, and I have observed that you generated AdWords responses using campaign criterion service and not using reports(AWQL/report definition).

Also, I have checked your account 1499018728 for your given GAQL, and I got a total of 69 results. I was able to replicate your issue on my end. The reason you got 65 having CriterionUserList object and the other 4 not having criterion at all is because userlist such as 798684141, 796287371, 797622031 and 796624826 do not exists like other rest of userlists 65 entries. This is the reason why you were not able to get the CriterionUserList object in Google Ads API. This is working as expected. 

However, to verify on your end you may use the below GAQL against your account 1499018728 :

SELECT user_list.id, user_list.name, user_list.type, user_list.account_user_list_status FROM user_list WHERE user_list.id IN (798684141,796287371, 797622031 , 796624826)

I hope this helps. Let us know if you have any additional questions.

Regards,

Google Logo
Yasar
Google Ads API Team
 


ref:_00D1U1174p._5004Q2YlJQf:ref

Ngon Nguyen

unread,
Mar 18, 2022, 6:34:45 AM3/18/22
to Google Ads API Forum Advisor, leosanche...@gmail.com, AdWords API and Google Ads API Forum

Vào 16:51, Th 6, 18 thg 3, 2022 Google Ads API Forum Advisor <ads...@forumsupport.google> đã viết:

Leo Sanchez

unread,
Mar 21, 2022, 4:53:05 PM3/21/22
to Google Ads API and AdWords API Forum
Hi Yasar,

Thank you for the reply, we still have more questions:

Why is this difference happening? Why is it normal to Google Ads API to have less data than the AdWords API? 

We thought that AdWords API always returns the "real" data and Google Ads API has to return exactly the same, hence the compare we implemented in the code. If that's not the case we would like to know why that behavior is the expected one.

Thanks!
Leo

Google Ads API Forum Advisor

unread,
Mar 22, 2022, 1:29:06 PM3/22/22
to leosanche...@gmail.com, adwor...@googlegroups.com
Hi Leo,

I working with Yasar. It is working as expected. In the Adwords API, you are using campaign criterion service code and so many other field you are not using AWQL. The userlist such as 798684141, 796287371, 797622031 and 796624826 does not exists like other rest of userlists 65 entries. That's why CriterionUserList object was not coming with those userlists in Ads API response. Let me know if you have any question.

Thanks,
Google Logo
Nirmita
Google Ads API Team
 


ref:_00D1U1174p._5004Q2YlJQf:ref

Leo Sanchez

unread,
Mar 22, 2022, 3:12:58 PM3/22/22
to Google Ads API and AdWords API Forum
Hi,

Thanks for the answer, so, just to confirm, you're saying that:
  • The AdWords API call using CampaignCriterionService interface will return all the CampaignCriteria with all the associated UserList to it, no matter if they still exist or not.
  • However the Google Ads call using GAQL returns all the CampaignCriteria without the UserList that in fact do not exist anymore, meaning that this call do cares about the existence of an object, whereas the other one does not.
This is what I get after all this conversation, can you guys confirm me this? 

Many thanks,
Leo

Google Ads API Forum Advisor

unread,
Mar 23, 2022, 11:45:19 AM3/23/22
to leosanche...@gmail.com, adwor...@googlegroups.com
Hi Leo,

Thank you for the reply. I'm also a member of the Google Ads API support team.

I already raised this issue to my team. Rest assured that we will provide updates when available.

Best regards,
Google Logo
Jinky
Google Ads API Team
 


ref:_00D1U1174p._5004Q2YlJQf:ref

Leo Sanchez

unread,
Mar 28, 2022, 1:04:54 PM3/28/22
to Google Ads API and AdWords API Forum
Hi,

I wanted to know if you were able to make progress with this issue.

Thanks,
Leo

Google Ads API Forum Advisor

unread,
Mar 29, 2022, 5:43:24 PM3/29/22
to leosanche...@gmail.com, adwor...@googlegroups.com
Hi Leo,

I've pinged the team for an update, and will share more details as I hear from the team.

Cheers
Anash

ref:_00D1U1174p._5004Q2YlJQf:ref

Leo Sanchez

unread,
Apr 8, 2022, 10:09:32 AM4/8/22
to Google Ads API and AdWords API Forum
Hi,

Were you guys able to gather more info about my last question?

I understand that maybe it's a simple and trivial question but given the fact that in changes functionality compared to AdWords, we need to know if we need to accommodate our code to support this. 

The AdWords API is about to go sunset as planned and this is something we still have in our backlog and we'd really want to find a solution to it.

Thanks,
Leo



Reply all
Reply to author
Forward
0 new messages