replace event snippet with gtag by gads API call for conversion

53 views
Skip to first unread message

luc .manfredi

unread,
Apr 21, 2022, 5:03:42 AM4/21/22
to Google Ads API and AdWords API Forum
Hi !

i'm trying to send conversion using the Google Ads API.

Actually, my company use the event snippet : 
<script>
  gtag('event', 'conversion', {'send_to': 'XXXXXX'});
</script>

And i want now to do the same action but with an API call.

I've tried to create a program using TagSnippet but i'm beginner and lost with this API :').

If you have any leads, I would be very grateful.

Thanks in advance !

Google Ads API Forum Advisor

unread,
Apr 22, 2022, 1:47:32 AM4/22/22
to luck...@hotmail.com, adwor...@googlegroups.com

Hi,
 

Thanks for reaching out to the Google Ads API Support team.
 

With regard to your concern, In Google Ads API the "TagSnippet" is the site tag and event snippet pair for a TrackingCodeType. However, I am afraid that it is not possible to update it in the Google Ads API. In the Google Ads API, you can just retrieve the information of TagSnippet including the event snippet using conversion_action
 

Let us know if you have any questions.


Regards,

Google Logo
Darwin
Google Ads API Team
 


ref:_00D1U1174p._5004Q2a5PAR:ref

luc .manfredi

unread,
Apr 25, 2022, 10:26:46 AM4/25/22
to Google Ads API and AdWords API Forum
I see upload conversion functions in examples/remarketing (uploadCallConversion, uploadConversionWithIdentifier), i try to use them but i have this error : No click was found for the given user identifiers that could be applied to the specified conversion action

I understand this is because I haven't tried it by clicking on ads before, but actually the examples should increment the value of a conversion_action like with the gtag script. It is really not possible to do the same action by taking example on UploadCall and the conversion of identifier?

Google Ads API Forum Advisor

unread,
Apr 26, 2022, 6:47:14 AM4/26/22
to luck...@hotmail.com, adwor...@googlegroups.com
Hi,

Thank you for the replies. I work with Darwin and allow me to assist you here.

To answer your question, I can say that the error you are encountering is CLICK_NOT_FOUND, could you please provide the complete request and response logs with request ID and request header that generated on your end? This information will help our team to further check. However, for the second question, yes this is not possible to do the same action as you need a valid GCLID to be uploaded as a conversion in the Google Ads API.

Best regards,
Google Logo
Jinky
Google Ads API Team
 


ref:_00D1U1174p._5004Q2a5PAR:ref

Google Ads API Forum Advisor

unread,
Apr 26, 2022, 6:49:34 AM4/26/22
to luck...@hotmail.com, adwor...@googlegroups.com
Hi,

For the complete API logs, you can provide it via Reply privately to the author option. If this option is not available, then send it instead on this email address googleadsa...@google.com.
Reply all
Reply to author
Forward
0 new messages