Unable to Add Logo Image in Responsive Display Ad

45 views
Skip to first unread message

Filip Pećanac

unread,
Oct 28, 2021, 5:36:29 AM10/28/21
to AdWords API and Google Ads API Forum
Hi,

I am having issues with adding Logo image via PHP library. 

I manage to add landscape and square image, but for some reason it doesn't work with Logo image.

This is a part of my code with logo instructions:

$marketingImageAssetResourceName = self::createImageAsset(
$googleAdsClient,
$customerId,
$options['imageUrl'],
'Marketing Image'
);
$squareMarketingImageAssetResourceName = self::createImageAsset(
$googleAdsClient,
$customerId,
$options['squareImageUrl'],
'Square Marketing Image'
);
$logoImageAssetRessourceName = self::createImageAsset(
$googleAdsClient,
$customerId,
$options['logoImageUrl'],
'Logo Image'
);

// Creates a responsive display ad info.
$responsiveDisplayAdInfo = new ResponsiveDisplayAdInfo([
// Sets some basic required information for the responsive display ad.
'headlines' => [new AdTextAsset(['text' => $options['headlines']])],
'long_headline' => new AdTextAsset(['text' => $options['longHeadline']]),
'descriptions' => [new AdTextAsset(['text' => $options['descriptions']])],
'business_name' => $options['businessName'],
'marketing_images' => [
new AdImageAsset(['asset' => $marketingImageAssetResourceName]),
],
'square_marketing_images' => [
new AdImageAsset(['asset' => $squareMarketingImageAssetResourceName]),
],
'logo_images' =>[
new AdImageAsset(['asset' => $logoImageAssetRessourceName])
],
// Optional: Sets call to action text, price prefix and promotion text.
'call_to_action_text' => $options['callToAction'],
]);

Could you please assist with this?

Thanks in advance!

Google Ads API Forum Advisor

unread,
Oct 28, 2021, 4:21:32 PM10/28/21
to filip....@oneassessment.com, adwor...@googlegroups.com

Hi Filip,

Could you privately provide us with logs of request and response to the API so that we can see what is happening? 

If you are using the Ads API, the request and response appears similar to the JSON Mappings in our REST documentation. Our client libraries have loggers with logging instructions, to see these instructions you can click on the client library you use in the sidebar of our client library guide and click on "Logging".

If you are using the AdWords API , then a request looks like the 3rd section in request and a response looks similar to response. Logging instructions are in the read.me on Github of each client library.

Setting the logger to 'DEBUG' will get the desired log.

Regards,

Google Logo
Aryeh Baker
Google Ads API Team
 
​​​​​​​

ref:_00D1U1174p._5004Q2QFwVI:ref

Filip Pećanac

unread,
Nov 1, 2021, 6:04:59 AM11/1/21
to AdWords API and Google Ads API Forum
Hi Aryeh,

Thanks for the response. 

Unfortunately, there are no logs of my requests and responses. 

I have followed the instructions from the Logging section and once I complete all the steps, there is no generated data in my file.log.

I am using web application if that is relevant for this.

Any advice would be beneficial.

Regards,
Filip

Google Ads API Forum Advisor

unread,
Nov 2, 2021, 1:18:53 AM11/2/21
to filip....@oneassessment.com, adwor...@googlegroups.com
Hi Filip,

Thank you for the reply. I am also a member of the Google Ads API team and let me provide support to your concern.

Could you confirm if there are no API logs as well in the console of your client library? If yes, then I am afraid that we would not be able to investigate the issue without the complete request and response logs with request ID and request header generated on your end.

With this, if there are no API logs in the console and in the file.log, then I would suggest to reach out to the author of the client library by clicking one of the links in the Source column of this page based on the client library that you are using. Then, navigate to the Issues tab and post your concern there to get help with your issue about logging of the API transactions as the author of the client library is more equipped to this issue.

After enabling the logging of the API transactions, you can revert back to us and provide the information that we are asking. Please provide it via Reply privately to author option. If this option is not available, then send it instead on this email address googleadsa...@google.com.

Regards,
Google Logo
Ernie John Blanca Tacata
Google Ads API Team
 


ref:_00D1U1174p._5004Q2QFwVI:ref
Reply all
Reply to author
Forward
0 new messages