Tag Archives: content_api

Reminder of upcoming Content API for Shopping v2.0 sunset date

In March of this year, we announced that beginning September 30, 2021, we will end support for the legacy v2.0 of the Content API for Shopping. We also recommended you migrate to using v2.1, which has been available since March 2019.

As of this announcement, there is now less than 1 month until support for v2.0 will end on September 30, 2021. Following this date, the legacy v2.0 of the Content API is no longer guaranteed to function. We will continue to provide support for your efforts to migrate to v2.1. To avoid disruption we strongly encourage you to migrate to v2.1 imminently.

What do I need to know?
To check your usage of Content API for Shopping, you can look it up: If your application uses a multi-client account (MCA) to make changes to sub-accounts, you should also check your API usage for that account. Please note that all API usage from Content API for Shopping v2.0, is no longer guaranteed to function after September 30, 2021.

Where do I get support?
We have a comprehensive migration guide to help you migrate your implementation including all the changes and new features available in v2.1.

For support migrating the Inventory.set method, see the release of partial product updates.

For support for Google Apps Script & Google Ads scripts, see the update of the default runtime to v2.1.

If you have any questions or issues during migration, contact your Google representative for Merchant Center programs, or ask questions in the Content API for Shopping forum.

Google Apps Script & Google Ads scripts now support Content API v2.1 by default

Going forward, if you use Content API for Shopping through Google Apps Script or Google Ads scripts, new scripts will use Content API v2.1 by default. This change is part of the deprecation of Content API for Shopping v2, scheduled for sunset on September 30th, 2021, after which scripts that depend on v2 features won’t work.

If you currently have a Google Apps script or Google Ads script that uses Content API for Shopping v2, then we strongly recommend you migrate to v2.1. Please note that some methods and fields in v2 are no longer supported in v2.1 (for example Inventory.set), so check the availability of methods and fields you use when you migrate. See the migration guide for more detail.

If you need help implementing this change, please visit the Content API for Shopping forum.

Phone Verification in Content API for Shopping

We are pleased to announce a new Content API interface developers can use to verify phone numbers for Merchant Center accounts. Phone verification is an important step in providing contact information for an account and can also help address account status issues such as PENDING_PHONE_VERIFICATION, which in some cases can enable the option for an account re-review. Prior to this release, this was only possible in the Merchant Center user interface.

Two new methods are provided in the 2-step verification process: Once verified, the phone number will appear in the Accounts.AccountBusinessInformation. The new methods replace the prior approach of setting a phone number directly. We strongly recommend you use these new methods to verify the phone numbers for all Merchant Center accounts to avoid future issues. See the Phone Verification guide for examples and more detail.

If you require further support implementing this change, please visit the Content API for Shopping forum.

Performance reporting now available in the Content API for Shopping

We're excited to announce that performance reporting is now available in v2.1 of the Content API for Shopping. With the search method of the Reports service, you can programmatically retrieve all of the performance data that's available in the Merchant Center.

Requests to the Reports service use the new Merchant Center Query Language, which gives you control over which metrics to download, how to segment/group your data, and which criteria to apply for selecting the result set. If you also use the reporting features of the Google Ads API, you’ll find that many of these concepts are familiar.

For example, the following query will result in a report of impressions, clicks, and clickthrough rate (CTR) over the last 30 days, summarized by date, brand, and offer ID.

SELECT
segments.date,
segments.brand,
segments.offer_id,
metrics.impressions,
metrics.clicks,
metrics.ctr
FROM MerchantPerformanceView
WHERE segments.date DURING LAST_30_DAYS
AND segments.category_l2 IN ('Clothing', 'Shoes')

For more details, check out the Reporting guides, which include an overview, a quick example to get you started, and an explanation of key concepts, including how to compose queries in the Merchant Center Query Language.

If you have any questions or need help with the new reporting service, please contact us through the Content API for Shopping forum.

Important changes to Google Contact Policy for Merchant Center

Following feedback from our merchants, we are relaxing our contact policy website requirements for merchants. Currently we require merchants to publicly display on their website at least two methods of contact information (such as an email, business address, or phone number).

To give merchants more flexibility in the information they share with customers, beginning August 2, 2021, we will require merchants to provide on their website a minimum of one form of customer-facing contact information, for example:
  • A “contact us” form
  • A link to a social media business profile
  • An email address
  • A phone number
In addition to this change, all new merchants will be required to provide their business address and phone number on creation of their Merchant Center account, as well as for any existing accounts that require a review. This private contact information can be entered manually in the Merchant Center user interface or via Content API for Shopping.

To update the private contact information using Content API for Shopping, provide both the address and phoneNumber fields via the AccountBusinessInformation object (nested under the Account object) using the following methods: Important: Take care when updating existing accounts. Any fields that are not provided to Accounts.update will be deleted from the resource.

Note: If you have made contact information changes to an existing Merchant Center account that has an account-level disapproval, you may need to request an account re-review. See the following article on Understanding account-level enforcement for product data quality violations to find the steps to make the request.
If you require further support implementing this change, please visit the Content API for Shopping forum.

Partial product updates now available in v2.1 of the Content API for Shopping

Today we are launching a new feature in Content API for Shopping v2.1: products.update.
The products.update method allows you to submit a subset of changes for a given product using the Products API. It works similarly to products.insert, but only requires the fields you would like to modify.

Users of inventory.set in Content API v2, will be familiar with the ability to provide updates to price, availability and other limited fields. The products.update method goes one step further and allows you to modify any fields that are mutable with products.insert. Users that are migrating from v2 to v2.1 ahead of the September 30, 2021 sunset date, might find this new functionality useful.

Products.update utilizes the HTTP PATCH method. Here is an example of updating the salePrice using REST:

HTTP request:

PATCH https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/products/{productId}


Example request body:

{
"salePrice": {
"value": "17.99",
"currency": "USD"
}
}

You can also provide product update operations as part of a products.custombatch request. For more examples and use-cases, see the products.update guide in the documentation.

If you require further support using this feature, please visit the Content API for Shopping forum.


Partial product updates now available in v2.1 of the Content API for Shopping

Today we are launching a new feature in Content API for Shopping v2.1: products.update.
The products.update method allows you to submit a subset of changes for a given product using the Products API. It works similarly to products.insert, but only requires the fields you would like to modify.

Users of inventory.set in Content API v2, will be familiar with the ability to provide updates to price, availability and other limited fields. The products.update method goes one step further and allows you to modify any fields that are mutable with products.insert. Users that are migrating from v2 to v2.1 ahead of the September 30, 2021 sunset date, might find this new functionality useful.

Products.update utilizes the HTTP PATCH method. Here is an example of updating the salePrice using REST:

HTTP request:

PATCH https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/products/{productId}


Example request body:

{
"salePrice": {
"value": "17.99",
"currency": "USD"
}
}

You can also provide product update operations as part of a products.custombatch request. For more examples and use-cases, see the products.update guide in the documentation.

If you require further support using this feature, please visit the Content API for Shopping forum.


Reminder: Using v2.0 of the Content API for Shopping with new accounts ends on April 30, 2021

In March, we announced that beginning April 30, 2021 we will no longer allow new merchant accounts onto v2.0 of the Content API for Shopping as part of the sunset process. With less than two weeks to go until the April deadline, here is a quick reminder of the details.

What do I need to know?
  • This account restriction will not impact users accessing new sub-accounts via an existing multi-client account (MCA), provided that MCA has been actively making v2.0 requests.
  • New accounts using v2.1 of the Content API for Shopping will not be affected.
  • The sunset date for existing merchant accounts actively using v2.0 is September 30, 2021.
What do I need to do?
  • Migrate to v2.1 of the Content API for Shopping in order to continue interacting with new merchant accounts after April 30, 2021.
  • If you are concerned you won’t be able to meet the April deadline, please fill out this form to request an exemption.
If you have any questions or issues during migration, contact your Google representative for Merchant Center programs, or ask questions in the Content API for Shopping forum.

Sunset grace period for existing v2 users of the Content API for Shopping

As we’ve previously announced, we will stop supporting legacy v2.0 of the Content API for Shopping in favor of v2.1, which has been available since March 2019.

As this has been a difficult year for all of us, in order to provide you ample time to migrate to v2.1 we will be extending the sunset date for existing merchant accounts actively using v2.0 to September 30, 2021. However, we will not allow new merchant accounts onto v2.0 after April 30, 2021. The account restrictions will not impact users accessing new sub-accounts via an existing multi-client account (MCA), provided that MCA has been actively making v2.0 requests.

We will publish another blog post in the coming weeks with a process for requesting an exemption to add new accounts to your v2.0 integration after April 30, 2021.

Throughout this grace period, we will continue to provide support for your efforts to migrate to v2.1. We strongly encourage you to migrate to v2.1 as soon as possible.

What do I need to know?
In March 2019, we released version 2.1 of the Content API for Shopping with major improvements to the API management experience for Merchant Center programs, including: See the complete list of changes in the release notes and the migration guide to help with the transition.

If you have any questions or issues during migration, contact your Google representative for Merchant Center programs, or ask questions in the Content API for Shopping forum.

What do I need to do?
Migrate to v2.1 of the Content API as soon as possible.

Changes to Content API request validation

What’s changing?

The Content API for Shopping will gradually roll out improvements to request validation from January 1, 2021 to February 15, 2021. These changes will be applied to a growing percentage of requests during that time, reaching 100% by February 15, 2021. The validation improvements will ensure that certain requests that are not in the proper format result in an error instead of having the Content API attempt to infer the request's intent. As long as you are submitting the proper type and structure for each field, you will not be affected by this change.

The following sections describe two examples of incorrectly formatted requests that may fail after January 1st, 2021. If your requests start to fail after January 1st, 2021, please refer to the error message returned and correct the formatting issue.

Example: Providing an invalid structure for a repeated field

This error applies to providing any invalid type for a repeated field, such as providing a list of objects instead of a list of strings, or vice versa.

Example invalid v2.1 request

The following request is invalid because the includedDestinations field requires a list of strings, not a list of objects:

{
"targetCountry": "US",
"offerId": "123",
"contentLanguage": "en",
"channel": "online",
"includedDestinations": [{"destinationName": "Shopping", "intention": "default"}]
}

Example valid v2.1 request

To correct this issue, change the list of objects to a list of strings:

{
"targetCountry": "US",
"offerId": "123",
"contentLanguage": "en",
"channel": "online",
"includedDestinations": ["Shopping", "SurfacesAcrossGoogle"]
}

Other common fields affected by this change

  • v2.1:
    • product.excluded_destinations (a common mistake is providing the v2 format of this field for requests to v2.1)
  • v2:
    • product.destinations (a common mistake is providing the v2.1 format of this field for requests to v2)
    • product.sizes
    • product.additional_image_links
    • product.shipping

Example: Submitting a string that represents a float instead of an integer

This error applies to providing a string containing a floating point number when an integer is required.

Example invalid v2.1 request

The following request is invalid because the sellOnGoogleQuantity requires a string in int64 format, but the string “100.0” is a float:

{
"targetCountry": "US",
"offerId": "123",
"contentLanguage": "en",
"channel": "online",
"sellOnGoogleQuantity": "100.0"
}

Example valid v2.1 request

To correct this issue, change the value to an integer:

{
"targetCountry": "US",
"offerId": "123",
"contentLanguage": "en",
"channel": "online",
"sellOnGoogleQuantity": "100"
}

Other common fields affected by this change

  • v2.1:
    • product.unit_pricing_base_measure.value
  • v2:
    • inventory.sell_on_google_quantity
    • product.unit_pricing_base_measure.value

What do I do?

We recommend that you address any incorrectly formatted requests before January 1st, 2021 to avoid any disruptions to your application.

If you are already submitting the proper type for each field as described in the Content API for Shopping reference docs, no action is required.

Need More Help?

If you have any questions or need assistance, please reach out to us on the forum.