field name for image in template ads

8 views
Skip to first unread message

Prashant Kumar

unread,
Jun 7, 2018, 6:01:32 PM6/7/18
to AdWords API and Google Ads API Forum
Hi,

The name used for the image inside my template elements looks like this :

 [ 5] {
                               :name => "product1MCImage",
                               :type => "IMAGE",
                        :field_media => {
                                :media_id => 2303767383,
                                    :type => "IMAGE",
                            :reference_id => -2601016678015827968,
                              :dimensions => {
                                "FULL" => {
                                     :width => 800,
                                    :height => 800
                                }
                            },

My question: Is it always that this will have "product" as it's prefix ?

And also will it always be in the 6th object (index 5) inside :template_elements ?

Thanks!


Vincent Racaza (AdWords API Team)

unread,
Jun 7, 2018, 11:41:37 PM6/7/18
to AdWords API and Google Ads API Forum
Hi Prashant,

For the templateElements of a TemplateAd, if you are adding a template element field as image or any other type, you can just set the name of your template element field to the specific value you wish as this is a required field.

Or, if you are referring to the name of the image itself, then I believe that the AdWords system will be the one to assign the image name if you won't set the name. If you will set the image name during creation, then it is also possible.

For the index of your template element, this depends on what template ad you are currently using. The number of template elements and indexing may vary per template ad.

Thanks,
Vincent
AdWords API Team
Reply all
Reply to author
Forward
0 new messages