How to remove TextAsset

214 views
Skip to first unread message

san...@knorex.com

unread,
Mar 29, 2023, 5:45:49 AM3/29/23
to Google Ads API and AdWords API Forum
Hi,
I want to delete my TextAsset.
In object "AssetOperation.Builder", there is only setCreate/setUpdate but setRemove.

Sang

Google Ads API Forum Advisor

unread,
Mar 29, 2023, 10:10:23 AM3/29/23
to san...@knorex.com, adwor...@googlegroups.com

Hi, 

Thanks for reaching out to the Google Ads API Team. I hope you are doing well today.

I understand that you want to delete a TextAsset. However as mentioned in the Google Ads API Asset creation and usage that “The AssetService only supports create operations. Once an asset is uploaded to an advertiser's account, it cannot be changed or removed programmatically. You must use ad-level operations to manage associations between individual assets and ads, as described below.”.

In line with this, you may try to use the setUpdate, for example, if you wanted to remove it from the ad, you would specify an empty array. “Keep in mind that although you want to remove, you are really just updating the details of the ad itself.”

Have a great day.

Regards,

Google Logo Google Ads API Team


ref:_00D1U1174p._5004Q2kCq2o:ref
Message has been deleted

Aniket Churihar

unread,
Apr 1, 2024, 1:41:27 PM4/1/24
to Google Ads API and AdWords API Forum
When you say this "You must use ad-level operations to manage associations between individual assets and ads, as described below.”. Do you mean that the google Ads API has some means to achieve this or does it needs to be done through the UI dashboard?

Google Ads API Forum Advisor

unread,
Apr 2, 2024, 10:35:09 PM4/2/24
to anike...@gmail.com, adwor...@googlegroups.com

Hi,

Kindly note that the Google Ads API does provide functionalities to manage associations between individual assets and ads, but it's done through ad-level operations, not the AssetService. The UI dashboard allows you to directly associate assets with ad groups or campaigns through the "Associations view". I would suggest you refer to the document Asset creation and usage to get more information.

I hope this helps. Kindly get back to us if you have any further queries.
 

This message is in relation to case "ref:!00D1U01174p.!5004Q02kCq2o:ref" (ADR-00172756)

Thanks,

 
Google Logo Google Ads API Team


Ashutosh Khetan

unread,
Apr 17, 2024, 4:31:34 AM4/17/24
to Google Ads API and AdWords API Forum
How do you remove the association of some automatically created assets (ACA) against a response search ad? Let's say I have 4 ACA created, and I see that one of these four is not safe. I want to delink it programmatically, but I can't figure out how to do so.

Also, when I tried fetching details of a responsive search ad, it didn't return details of the linking between ACA and itself. Please help

Google Ads API Forum Advisor

unread,
Apr 17, 2024, 2:13:05 PM4/17/24
to ashu....@gmail.com, adwor...@googlegroups.com
Hi,

Yes, you can remove individual assets via API. As per this guide, you can remove CampaignAsset, AdGroupAsset, or CustomerAsset entities that associate the automated asset with the corresponding resource. I would recommend that you set the status of the asset to 'REMOVED' to remove the association.

Hope this helps.

Ashutosh Khetan

unread,
Apr 18, 2024, 4:19:03 AM4/18/24
to Google Ads API and AdWords API Forum
This approach doesn't work for Headline assets. Please suggest how it could be done for headline assets. 

My automatically created asset(ACA) is a Headline Asset associated with an RSA Ad, but it was created at the campaign level. This was done by enabling the ACA flag at the campaign level on Google Ads UI. 

I ran the below query to get the ID details of my ACA (Headline ACA for RSA ad), 
SELECT
  ad_group.name,
  ad_group_ad_asset_view
.asset,
  ad_group_ad_asset_view
.ad_group_ad
FROM ad_group_ad_asset_view
WHERE asset.source = 'AUTOMATICALLY_CREATED'

Even after identifying the resource ID of this HEADLINE asset using Google UI and the above-mentioned query, if I try removing it using the  CampaignAssetAdGroupAsset  service you mentioned above, I get a resource not found message.

Can I please understand the way to move ahead. 

I intend to remove the association of a Headline ACA associated with the RSA ad, which I cannot achieve as outlined above. Any help is highly appreciated.

Google Ads API Forum Advisor

unread,
Apr 19, 2024, 3:32:52 AM4/19/24
to ashu....@gmail.com, adwor...@googlegroups.com
Hi,

Upon checking the provided information, I understand that you are getting a RESOURCE_NOT_FOUND error,  which is one of the common mutate errors. The common cause is when the request attempts to mutate or otherwise reference a resource that does not exist or has been removed. Or, the given resource name for the resource is malformed. To handle this, use a search request to retrieve the resource name for an existing resource before submitting a mutate request. Let us know if you still have further queries. 

Also, kindly provide us with the complete API logs (request and response with request-id and request header) generated at your end that you are using to get the ID details to better assist you on this request. 

If you are using a client library and haven't enabled the logging yet, I would request you to enable logging for the specific client library that you are using. You can refer to the guides Java, .Net, PHP, Python, Ruby or Perl to enable logging at your end. For REST interface requests, you can enable logging via the curl command by using the -i flag.

You can share the requested details via Reply privately to the author option or a direct private reply to this email.
Reply all
Reply to author
Forward
0 new messages