Перенести статусы аккаунтов в агрегированные статусы продуктов
Оптимизируйте свои подборки
Сохраняйте и классифицируйте контент в соответствии со своими настройками.
Изменился способ получения агрегированной статистики товаров и информации о проблемах. Функциональность, ранее доступная в ресурсе accountstatuses в Content API for Shopping, теперь выделена в отдельные ресурсы в Merchant API. В этом руководстве объясняется, как перенести интеграцию для использования нового ресурса aggregateProductStatuses .
Примечание : в Merchant API проблемы на уровне аккаунта и агрегированные статусы товаров разделены. Также ознакомьтесь с нашим руководством по переходу от accountstatuses к проблемам аккаунта .
Ключевые отличия
Ниже приведены основные различия между функциями статуса продукта в Content API for Shopping и Merchant API:
Выделенные ресурсы : ресурс accountstatuses из Content API for Shopping теперь разделён. В Merchant API проблемы на уровне аккаунта доступны через ресурс accountissues , а агрегированная статистика товаров и проблемы на уровне товаров — через новый ресурс aggregateProductStatuses .
Новая структура ресурсов : AggregateProductStatus — это новый ресурс, который представляет статистику и проблемы для определенной комбинации контекста отчетности и страны.
Механизм фильтрации : вместо использования параметров запроса, таких как destinations для выбора данных, API торговца использует метод list со строкой filter для запроса определенных контекстов отчетности и стран.
Удаление поля канала : Поле channel больше не используется. Эта информация теперь неявно является частью reportingContext .
Запросы
API продавца использует GET запрос с параметром filter для получения агрегированных статусов продуктов.
GET https://merchantapi.googleapis.com/issueresolution/v1/{parent=accounts/*}/aggregateProductStatuses
Формат URL запроса
Запросить описание
API контента для покупок
API торговца
Получите статистику и информацию о проблемах с продуктами
GET /content/v2.1/{merchantId}/accountstatuses/{accountId}
GET /issueresolution/v1/accounts/{accountId}/aggregateProductStatuses
Идентификаторы
Для поддержки новой структуры изменился способ определения ресурсов.
Формат идентификатора
Описание идентификатора
API контента для покупок
API торговца
Идентификатор ресурса
Ресурс был идентифицирован по accountId . Конкретные фрагменты данных были выбраны с помощью параметров запроса.
Имя ресурса однозначно идентифицирует данные для конкретного контекста отчетности и страны: accounts/{account}/aggregateProductStatuses/{reportingContext}~{country} .
Методы
Метод получения статусов продуктов обновлен до метода list , поддерживающего фильтрацию.
API контента для метода покупок
Метод API торговца
Доступность и примечания
accountstatuses.get
aggregateProductStatuses.list
Метод accountstatuses.get вернул один ресурс, содержащий всю статистику по продуктам. Новый метод aggregateProductStatuses.list возвращает список ресурсов, по одному для каждой комбинации контекста отчётности и страны. Используйте параметр filter для получения конкретных данных. Для проблем на уровне аккаунта используйте accountissues.list .
Подробные изменения полей
Поля для статистики и проблем с продуктами были обновлены и реструктурированы в новом ресурсе AggregateProductStatus .
API контента для покупок
API торговца
Описание
products
aggregate_product_statuses
Массив products заменяется повторяющимся полем aggregate_product_statuses в ответе списка.
destination
reporting_context
Поле destination заменяется на reporting_context , которое указывает программный контекст для статистики.
channel
(нет эквивалентного поля)
Поле channel удалено. Теперь эта информация является частью reporting_context .
statistics
stats
Объект statistics переименован в stats . Имена полей в нём преобразуются в формат snake_case, например, activeCount теперь называется active_count .
itemLevelIssues.servability
item_level_issues.severity
Перечисление servability заменяется перечислением severity для описания влияния проблемы.
itemLevelIssues.attributeName
item_level_issues.attribute
Поле attributeName переименовано в attribute .
itemLevelIssues.documentation
item_level_issues.documentation_uri
Поле documentation переименовано в documentation_uri .
[[["Прост для понимания","easyToUnderstand","thumb-up"],["Помог мне решить мою проблему","solvedMyProblem","thumb-up"],["Другое","otherUp","thumb-up"]],[["Отсутствует нужная мне информация","missingTheInformationINeed","thumb-down"],["Слишком сложен/слишком много шагов","tooComplicatedTooManySteps","thumb-down"],["Устарел","outOfDate","thumb-down"],["Проблема с переводом текста","translationIssue","thumb-down"],["Проблемы образцов/кода","samplesCodeIssue","thumb-down"],["Другое","otherDown","thumb-down"]],["Последнее обновление: 2025-08-08 UTC."],[],[],null,["# Migrate accountstatuses to Aggregate Product Statuses\n\nThe way you retrieve aggregated product statistics and issues has changed. The\nfunctionality previously available in the `accountstatuses` resource in the\nContent API for Shopping is now split into dedicated resources in the Merchant\nAPI. This guide explains how to migrate your integration to use the new\n[`aggregateProductStatuses`](/merchant/api/reference/rest/issueresolution_v1/accounts.aggregateProductStatuses)\nresource.\n\n**Note** : In Merchant API, account-level issues and aggregate product statuses\nare split. Also review our guide to migrate from `accountstatuses` to\n[account issues](/merchant/api/guides/compatibility/migrate-view-issues).\n\nKey differences\n---------------\n\nHere are the key differences between the product status features in Content\nAPI for Shopping and Merchant API:\n\n- **Dedicated resources** : The `accountstatuses` resource from Content API for Shopping is now split. In Merchant API, account-level issues are available through the [`accountissues`](/merchant/api/reference/rest/accounts_v1/accounts.issues) resource, while aggregated product statistics and item-level issues are available through the new [`aggregateProductStatuses`](/merchant/api/reference/rest/issueresolution_v1/accounts.aggregateProductStatuses) resource.\n- **New resource structure** : `AggregateProductStatus` is a new resource that represents the statistics and issues for a specific combination of a reporting context and a country.\n- **Filtering mechanism** : Instead of using query parameters like `destinations` to select data, Merchant API uses a `list` method with a `filter` string to query for specific reporting contexts and countries.\n- **Channel field removal** : The `channel` field is no longer used. This information is now implicitly part of the `reportingContext`.\n\nRequests\n--------\n\nMerchant API uses a `GET` request with a `filter` parameter to retrieve\naggregated product statuses.\n\n`GET\nhttps://merchantapi.googleapis.com/issueresolution/v1/{parent=accounts/*}/aggregateProductStatuses`\n\n### Request URL format\n\n| Request description | Content API for Shopping | Merchant API |\n|-----------------------------------|--------------------------------------------------------------|-------------------------------------------------------------------------|\n| Get product statistics and issues | `GET /content/v2.1/{merchantId}/accountstatuses/{accountId}` | `GET /issueresolution/v1/accounts/{accountId}/aggregateProductStatuses` |\n\nIdentifiers\n-----------\n\nThe way resources are identified has changed to support the new structure.\n\n### Identifier format\n\n| Identifier description | Content API for Shopping | Merchant API |\n|------------------------|-------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Resource Identifier | The resource was identified by `accountId`. Specific data slices were selected with query parameters. | The resource name uniquely identifies the data for a specific reporting context and country: `accounts/{account}/aggregateProductStatuses/{reportingContext}~{country}`. |\n\nMethods\n-------\n\nThe method for retrieving product statuses has been updated to a `list` method\nthat supports filtering.\n\n| Content API for Shopping method | Merchant API method | Availability \\& notes |\n|---------------------------------|---------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `accountstatuses.get` | `aggregateProductStatuses.list` | The `accountstatuses.get` method returned a single resource containing all product statistics. The new `aggregateProductStatuses.list` method returns a list of resources, one for each reporting context and country combination. Use the `filter` parameter to retrieve specific data. For account-level issues, use `accountissues.list`. |\n\nDetailed field changes\n----------------------\n\nThe fields for product statistics and issues have been updated and restructured\nin the new `AggregateProductStatus` resource.\n\n| Content API for Shopping | Merchant API | Description |\n|---------------------------------|---------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------|\n| `products` | `aggregate_product_statuses` | The `products` array is replaced by the `aggregate_product_statuses` repeated field in the list response. |\n| `destination` | `reporting_context` | The `destination` field is replaced by `reporting_context`, which specifies the program context for the stats. |\n| `channel` | (no equivalent field) | The `channel` field is removed. This information is now part of the `reporting_context`. |\n| `statistics` | `stats` | The `statistics` object is renamed to `stats`. Field names within are converted to snake_case, for example, `activeCount` is now `active_count`. |\n| `itemLevelIssues.servability` | `item_level_issues.severity` | The `servability` enum is replaced by the `severity` enum to describe the impact of an issue. |\n| `itemLevelIssues.attributeName` | `item_level_issues.attribute` | The field `attributeName` is renamed to `attribute`. |\n| `itemLevelIssues.documentation` | `item_level_issues.documentation_uri` | The field `documentation` is renamed to `documentation_uri`. |\n| `itemLevelIssues.numItems` | `item_level_issues.product_count` | The field `numItems` is renamed to `product_count`. |"]]